Skip to content

Commit

Permalink
bitshares#531: Catch some app init errors and redirect, update indexe…
Browse files Browse the repository at this point in the history
…ddbshim
  • Loading branch information
svk31 committed Oct 11, 2017
1 parent fb55b69 commit 6773724
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
10 changes: 9 additions & 1 deletion app/routerTransition.js
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,10 @@ const willTransitionTo = (nextState, replaceState, callback, appInit=true) => {
SettingsActions.changeSetting({setting: "activeNode", value: connectionManager.url});
callback();
});
}).catch(err => {
console.error(err);
replaceState("/init-error");
callback();
});
};

Expand Down Expand Up @@ -192,7 +196,11 @@ const willTransitionTo = (nextState, replaceState, callback, appInit=true) => {

/* Only try initialize the API with connect = true on the first onEnter */
connect = false;
}));
})).catch(err => {
console.error(err);
replaceState("/init-error");
callback();
});


// Every 15 connections we check the latencies of the full list of nodes
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@
"fractional": "^1.0.0",
"highcharts": "4.2.6",
"immutable": "^3.8.1",
"indexeddbshim": "^2.0.4",
"indexeddbshim": "^2.2.1",
"intl": "^1.1.0",
"jdenticon": "git+https://github.com/cryptonomex/jdenticon.git",
"js-sha256": "^0.2.3",
Expand Down

0 comments on commit 6773724

Please sign in to comment.