aboutsummaryrefslogtreecommitdiffstats
path: root/packages/utils/src
diff options
context:
space:
mode:
authorLeonid Logvinov <logvinov.leon@gmail.com>2018-05-31 05:41:36 +0800
committerLeonid Logvinov <logvinov.leon@gmail.com>2018-06-01 02:04:05 +0800
commita7fc9caacb7b98c7d79333e60ee9862945a67ecc (patch)
treed26d61dd0b2f19d68f34b4de460fa0cb225622d6 /packages/utils/src
parentc284f6dcd4e10388e0dd474be08788ddef6b4f30 (diff)
downloaddexon-sol-tools-a7fc9caacb7b98c7d79333e60ee9862945a67ecc.tar
dexon-sol-tools-a7fc9caacb7b98c7d79333e60ee9862945a67ecc.tar.gz
dexon-sol-tools-a7fc9caacb7b98c7d79333e60ee9862945a67ecc.tar.bz2
dexon-sol-tools-a7fc9caacb7b98c7d79333e60ee9862945a67ecc.tar.lz
dexon-sol-tools-a7fc9caacb7b98c7d79333e60ee9862945a67ecc.tar.xz
dexon-sol-tools-a7fc9caacb7b98c7d79333e60ee9862945a67ecc.tar.zst
dexon-sol-tools-a7fc9caacb7b98c7d79333e60ee9862945a67ecc.zip
Introduce ethereum-types package
Diffstat (limited to 'packages/utils/src')
-rw-r--r--packages/utils/src/abi_decoder.ts4
-rw-r--r--packages/utils/src/abi_utils.ts2
2 files changed, 3 insertions, 3 deletions
diff --git a/packages/utils/src/abi_decoder.ts b/packages/utils/src/abi_decoder.ts
index d2d8364ca..ed3297ee1 100644
--- a/packages/utils/src/abi_decoder.ts
+++ b/packages/utils/src/abi_decoder.ts
@@ -8,7 +8,7 @@ import {
LogWithDecodedArgs,
RawLog,
SolidityTypes,
-} from '@0xproject/types';
+} from 'ethereum-types';
import * as ethers from 'ethers';
import * as _ from 'lodash';
@@ -22,7 +22,7 @@ export class AbiDecoder {
_.forEach(abiArrays, this.addABI.bind(this));
}
// This method can only decode logs from the 0x & ERC20 smart contracts
- public tryToDecodeLogOrNoop<ArgsType>(log: LogEntry): LogWithDecodedArgs<ArgsType> | RawLog {
+ public tryToDecodeLogOrNoop<ArgsType extends DecodedLogArgs>(log: LogEntry): LogWithDecodedArgs<ArgsType> | RawLog {
const methodId = log.topics[0];
const event = this._methodIds[methodId];
if (_.isUndefined(event)) {
diff --git a/packages/utils/src/abi_utils.ts b/packages/utils/src/abi_utils.ts
index c4533d42e..b5822425c 100644
--- a/packages/utils/src/abi_utils.ts
+++ b/packages/utils/src/abi_utils.ts
@@ -1,4 +1,4 @@
-import { AbiDefinition, AbiType, ConstructorAbi, ContractAbi, DataItem, MethodAbi } from '@0xproject/types';
+import { AbiDefinition, AbiType, ConstructorAbi, ContractAbi, DataItem, MethodAbi } from 'ethereum-types';
import * as _ from 'lodash';
export const abiUtils = {