Skip to content

Commit

Permalink
Fix: visualization wasn't loading on first page load
Browse files Browse the repository at this point in the history
  • Loading branch information
arikfr committed Dec 27, 2016
1 parent 894da61 commit b3d0f70
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions client/app/services/query-result.js
Original file line number Diff line number Diff line change
Expand Up @@ -312,6 +312,10 @@ function QueryResultService($resource, $timeout, $q) {
}

prepareFilters() {
if (!this.getColumns()) {
return;
}

const filters = [];
const filterTypes = ['filter', 'multi-filter', 'multiFilter'];

Expand Down
2 changes: 1 addition & 1 deletion client/app/visualizations/chart/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ function ChartRenderer() {
}

function reloadData() {
if (!isUndefined($scope.queryResult)) {
if (!isUndefined($scope.queryResult) && $scope.queryResult.getData()) {
const data = $scope.queryResult.getChartData($scope.options.columnMapping);
$scope.chartSeries = sortBy(data, zIndexCompare);
}
Expand Down

0 comments on commit b3d0f70

Please sign in to comment.