diff options
Fix network checking
Diffstat (limited to 'app/scripts/keyring-controller.js')
-rw-r--r-- | app/scripts/keyring-controller.js | 22 |
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) |