Skip to content

Commit

Permalink
Visualization render status - pass correct parameters to resize check (
Browse files Browse the repository at this point in the history
…#15855)

* pass correct parameters to hasChangedUsingGenericHashComparison

* handle case where size parameter is not set
  • Loading branch information
nreese committed Jan 9, 2018
1 parent 4f15c6e commit 1d12c49
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/ui/public/vis/update_status.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,12 +51,13 @@ const getUpdateStatus = ($scope) => {
}

const time = $scope.vis.params.timeRange ? $scope.vis.params.timeRange : $scope.vis.API.timeFilter.getBounds();

const width = $scope.vis.size ? $scope.vis.size[0] : 0;
const height = $scope.vis.size ? $scope.vis.size[1] : 0;
return {
aggs: hasChangedUsingGenericHashComparison('aggs', $scope.vis.aggs),
data: hasChangedUsingGenericHashComparison('data', $scope.visData),
params: hasChangedUsingGenericHashComparison('param', $scope.vis.params),
resize: hasSizeChanged($scope.vis.size),
resize: hasSizeChanged(width, height),
time: hasChangedUsingGenericHashComparison('time', time),
uiState: hasChangedUsingGenericHashComparison('uiState', $scope.uiState)
};
Expand Down

0 comments on commit 1d12c49

Please sign in to comment.