Add Kredits preflight checks
This should identify potential config issues and print a usefull error message. e.g. if ipfs is not available.
This commit is contained in:
@@ -8,6 +8,10 @@ export default Route.extend({
|
|||||||
const kredits = this.kredits;
|
const kredits = this.kredits;
|
||||||
|
|
||||||
return kredits.setup().then(() => {
|
return kredits.setup().then(() => {
|
||||||
|
kredits.get('kredits').preflightChecks().catch((error) => {
|
||||||
|
console.error('Kredits preflight check failed!');
|
||||||
|
console.error(error);
|
||||||
|
});
|
||||||
if (kredits.get('accountNeedsUnlock')) {
|
if (kredits.get('accountNeedsUnlock')) {
|
||||||
if (confirm('It looks like you have an Ethereum wallet available. Please unlock your account.')) {
|
if (confirm('It looks like you have an Ethereum wallet available. Please unlock your account.')) {
|
||||||
transition.retry();
|
transition.retry();
|
||||||
|
|||||||
Reference in New Issue
Block a user