aboutsummaryrefslogtreecommitdiffstats
path: root/packages/base-contract/src/index.ts
diff options
context:
space:
mode:
authorLeonid Logvinov <logvinov.leon@gmail.com>2018-09-21 18:05:13 +0800
committerLeonid Logvinov <logvinov.leon@gmail.com>2018-09-21 18:05:13 +0800
commit393f9e5a293511ede662907861cf72e4f8add098 (patch)
tree6a4ba0832bcbcc48942790fcc6e22780475b36b4 /packages/base-contract/src/index.ts
parent79cf6969f9fb4eedb48d790449663780d1516a43 (diff)
downloaddexon-sol-tools-393f9e5a293511ede662907861cf72e4f8add098.tar
dexon-sol-tools-393f9e5a293511ede662907861cf72e4f8add098.tar.gz
dexon-sol-tools-393f9e5a293511ede662907861cf72e4f8add098.tar.bz2
dexon-sol-tools-393f9e5a293511ede662907861cf72e4f8add098.tar.lz
dexon-sol-tools-393f9e5a293511ede662907861cf72e4f8add098.tar.xz
dexon-sol-tools-393f9e5a293511ede662907861cf72e4f8add098.tar.zst
dexon-sol-tools-393f9e5a293511ede662907861cf72e4f8add098.zip
Fix the way we detect BN's
Diffstat (limited to 'packages/base-contract/src/index.ts')
-rw-r--r--packages/base-contract/src/index.ts2
1 files changed, 1 insertions, 1 deletions
diff --git a/packages/base-contract/src/index.ts b/packages/base-contract/src/index.ts
index 35c830a46..90e576c24 100644
--- a/packages/base-contract/src/index.ts
+++ b/packages/base-contract/src/index.ts
@@ -61,7 +61,7 @@ export class BaseContract {
}
}
protected static _bnToBigNumber(_type: string, value: any): any {
- return _.isObject(value) && value._bn ? new BigNumber(value.toString()) : value;
+ return _.isObject(value) && value._hex ? new BigNumber(value.toString()) : value;
}
protected static async _applyDefaultsToTxDataAsync<T extends Partial<TxData | TxDataPayable>>(
txData: T,