diff options
author | Chi Kei Chan <chikeichan@gmail.com> | 2017-10-25 07:50:25 +0800 |
---|---|---|
committer | Chi Kei Chan <chikeichan@gmail.com> | 2017-10-25 07:50:25 +0800 |
commit | 7c2001102311d8e35f01d39ede9d5ac00e635006 (patch) | |
tree | 7ac6ad5567cb9731e8d19159ba339e4e5d73cb44 /app/scripts | |
parent | ac3072e037ee97e87ff405d4562ce7e7c00dcd8a (diff) | |
parent | ae56b865e8a4d3a6a82a97efeca34b8a592c985b (diff) | |
download | tangerine-wallet-browser-7c2001102311d8e35f01d39ede9d5ac00e635006.tar tangerine-wallet-browser-7c2001102311d8e35f01d39ede9d5ac00e635006.tar.gz tangerine-wallet-browser-7c2001102311d8e35f01d39ede9d5ac00e635006.tar.bz2 tangerine-wallet-browser-7c2001102311d8e35f01d39ede9d5ac00e635006.tar.lz tangerine-wallet-browser-7c2001102311d8e35f01d39ede9d5ac00e635006.tar.xz tangerine-wallet-browser-7c2001102311d8e35f01d39ede9d5ac00e635006.tar.zst tangerine-wallet-browser-7c2001102311d8e35f01d39ede9d5ac00e635006.zip |
Merge branch 'master' into NewUI-flat
Diffstat (limited to 'app/scripts')
-rw-r--r-- | app/scripts/controllers/network.js | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/app/scripts/controllers/network.js b/app/scripts/controllers/network.js index 0f9db4d53..7f0cbd379 100644 --- a/app/scripts/controllers/network.js +++ b/app/scripts/controllers/network.js @@ -51,6 +51,10 @@ module.exports = class NetworkController extends EventEmitter { } lookupNetwork () { + // Prevent firing when provider is not defined. + if (!this.ethQuery || !this.ethQuery.sendAsync) { + return + } this.ethQuery.sendAsync({ method: 'net_version' }, (err, network) => { if (err) return this.setNetworkState('loading') log.info('web3.getNetwork returned ' + network) |