aboutsummaryrefslogtreecommitdiffstats
path: root/app
diff options
context:
space:
mode:
authorDan Finlay <dan@danfinlay.com>2016-11-05 03:11:00 +0800
committerDan Finlay <dan@danfinlay.com>2016-11-05 03:11:00 +0800
commitfc26a0a8991759a54409096d0c7896da86cea4b7 (patch)
treead67d22b42f4fd1aa91876d2facf4d38a3409f11 /app
parente3fb7fa7bbe28dcdb3202c6b228700d5812fbdf9 (diff)
downloadtangerine-wallet-browser-fc26a0a8991759a54409096d0c7896da86cea4b7.tar
tangerine-wallet-browser-fc26a0a8991759a54409096d0c7896da86cea4b7.tar.gz
tangerine-wallet-browser-fc26a0a8991759a54409096d0c7896da86cea4b7.tar.bz2
tangerine-wallet-browser-fc26a0a8991759a54409096d0c7896da86cea4b7.tar.lz
tangerine-wallet-browser-fc26a0a8991759a54409096d0c7896da86cea4b7.tar.xz
tangerine-wallet-browser-fc26a0a8991759a54409096d0c7896da86cea4b7.tar.zst
tangerine-wallet-browser-fc26a0a8991759a54409096d0c7896da86cea4b7.zip
Fix network checking
Diffstat (limited to 'app')
-rw-r--r--app/scripts/keyring-controller.js22
1 files changed, 1 insertions, 21 deletions
diff --git a/app/scripts/keyring-controller.js b/app/scripts/keyring-controller.js
index 1ca34e0f2..fb3091143 100644
--- a/app/scripts/keyring-controller.js
+++ b/app/scripts/keyring-controller.js
@@ -38,7 +38,7 @@ module.exports = class KeyringController extends EventEmitter {
this._unconfTxCbs = {}
this._unconfMsgCbs = {}
- this.network = null
+ this.network = opts.network
// TEMPORARY UNTIL FULL DEPRECATION:
this.idStoreMigrator = new IdStoreMigrator({
@@ -69,7 +69,6 @@ module.exports = class KeyringController extends EventEmitter {
conversionDate: this.configManager.getConversionDate(),
keyringTypes: this.keyringTypes.map((krt) => krt.type()),
identities: this.identities,
- network: this.network,
}
}
@@ -534,25 +533,6 @@ module.exports = class KeyringController extends EventEmitter {
}
}
- getNetwork(err) {
- if (err) {
- this.network = 'loading'
- this.emit('update')
- }
-
- this.web3.version.getNetwork((err, network) => {
- if (err) {
- this.network = 'loading'
- return this.emit('update')
- }
- if (global.METAMASK_DEBUG) {
- console.log('web3.getNetwork returned ' + network)
- }
- this.network = network
- this.emit('update')
- })
- }
-
addGasBuffer(gasHex) {
var gas = new BN(gasHex, 16)
var buffer = new BN('100000', 10)