@@ -118796,26 +118796,6 @@
118796
118796
}
118797
118797
return output;
118798
118798
}),
118799
- (Array.prototype.getUnique = function() {
118800
- for (var u = {}, a = [], i = 0, l = this.length; i < l; ++i)
118801
- u.hasOwnProperty(this[i]) ||
118802
- (a.push(this[i]), (u[this[i]] = 1));
118803
- return a;
118804
- }),
118805
- (Array.prototype.max = function() {
118806
- return Math.max.apply(null, this);
118807
- }),
118808
- (Array.prototype.min = function() {
118809
- return Math.min.apply(null, this);
118810
- }),
118811
- (Array.prototype.equals = function(b) {
118812
- if (this === b) return !0;
118813
- if (null == this || null == b) return !1;
118814
- if (this.length != b.length) return !1;
118815
- for (var i = 0; i < this.length; ++i)
118816
- if (this[i] !== b[i]) return !1;
118817
- return !0;
118818
- }),
118819
118799
(Math.sign =
118820
118800
Math.sign ||
118821
118801
function(x) {
@@ -129403,25 +129383,30 @@
129403
129383
);
129404
129384
}),
129405
129385
(self.initNetwork = function(callback) {
129406
- self.web3.version.getNetwork(function(error, version) {
129407
- error ||
129408
- !version ||
129409
- 1 === Number(version) ||
129410
- self.config.ethTestnet ||
129411
- self.dialogError(
129412
- 'You are connected to the Ethereum testnet. Please connect to the Ethereum mainnet.'
129413
- );
129414
- var ethGasPriceCookie = self.utility.readCookie(
129415
- 'ethGasPrice'
129416
- );
129417
- if (ethGasPriceCookie) {
129418
- var newEthGasPrice = JSON.parse(ethGasPriceCookie);
129419
- newEthGasPrice > self.config.ethGasPrice
129420
- ? self.setGasPrice(newEthGasPrice, !0)
129421
- : self.setGasPrice(self.config.ethGasPrice, !0);
129422
- } else self.setGasPrice(self.config.ethGasPrice, !0);
129423
- callback();
129424
- });
129386
+ try {
129387
+ self.web3.version.getNetwork(function(error, version) {
129388
+ error ||
129389
+ !version ||
129390
+ 1 === Number(version) ||
129391
+ self.config.ethTestnet ||
129392
+ self.dialogError(
129393
+ 'You are connected to the Ethereum testnet. Please connect to the Ethereum mainnet.'
129394
+ );
129395
+ var ethGasPriceCookie = self.utility.readCookie(
129396
+ 'ethGasPrice'
129397
+ );
129398
+ if (ethGasPriceCookie) {
129399
+ var newEthGasPrice = JSON.parse(ethGasPriceCookie);
129400
+ newEthGasPrice > self.config.ethGasPrice
129401
+ ? self.setGasPrice(newEthGasPrice, !0)
129402
+ : self.setGasPrice(self.config.ethGasPrice, !0);
129403
+ } else self.setGasPrice(self.config.ethGasPrice, !0);
129404
+ callback();
129405
+ });
129406
+ } catch (err) {
129407
+ console.error(err);
129408
+ throw err;
129409
+ }
129425
129410
}),
129426
129411
(self.initAPI = function(callback) {
129427
129412
Array.isArray(self.config.socketServer) &&
0 commit comments