mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 01:39:44 +01:00
Merge pull request #230 from MetaMask/i150
idStore - track network failure
This commit is contained in:
commit
1d65160ab4
@ -131,7 +131,10 @@ IdentityStore.prototype.revealAccount = function(cb) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
IdentityStore.prototype.getNetwork = function(tries) {
|
IdentityStore.prototype.getNetwork = function(tries) {
|
||||||
if (tries === 0) return
|
if (tries === 0) {
|
||||||
|
this._currentState.network = 'error'
|
||||||
|
return
|
||||||
|
}
|
||||||
this.web3.version.getNetwork((err, network) => {
|
this.web3.version.getNetwork((err, network) => {
|
||||||
if (err) {
|
if (err) {
|
||||||
return this.getNetwork(tries - 1, cb)
|
return this.getNetwork(tries - 1, cb)
|
||||||
|
Loading…
Reference in New Issue
Block a user