Skip to content

Commit

Permalink
Fixed a bug with new dashboard
Browse files Browse the repository at this point in the history
  • Loading branch information
vera-liu committed Nov 11, 2016
1 parent 90f00c5 commit f25d6d5
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions superset/assets/javascripts/dashboard/Dashboard.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,11 @@ export function getInitialState(dashboardData, context) {
dashboard.firstLoad = true;

dashboard.posDict = {};
dashboard.position_json.forEach(position => {
dashboard.posDict[position.slice_id] = position;
});
if (dashboard.position_json) {
dashboard.position_json.forEach(position => {
dashboard.posDict[position.slice_id] = position;
});
}
dashboard.curUserId = dashboard.context.user_id;
dashboard.refreshTimer = null;

Expand Down

0 comments on commit f25d6d5

Please sign in to comment.