diff options
author | Leonid Logvinov <logvinov.leon@gmail.com> | 2018-03-28 22:26:05 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-03-28 22:26:05 +0800 |
commit | 8926dac78c3ac8d75ad5ffd5b4febe36def4e53c (patch) | |
tree | 01c1b3f8dba486beb4e83e67ad0bc35c3da6a14e /packages/contracts | |
parent | 18cac3f0927a0424e3618fd56dba73fc9dfc0288 (diff) | |
parent | 01e27426d643b525661e044dbb8c8f27734329e7 (diff) | |
download | dexon-sol-tools-8926dac78c3ac8d75ad5ffd5b4febe36def4e53c.tar dexon-sol-tools-8926dac78c3ac8d75ad5ffd5b4febe36def4e53c.tar.gz dexon-sol-tools-8926dac78c3ac8d75ad5ffd5b4febe36def4e53c.tar.bz2 dexon-sol-tools-8926dac78c3ac8d75ad5ffd5b4febe36def4e53c.tar.lz dexon-sol-tools-8926dac78c3ac8d75ad5ffd5b4febe36def4e53c.tar.xz dexon-sol-tools-8926dac78c3ac8d75ad5ffd5b4febe36def4e53c.tar.zst dexon-sol-tools-8926dac78c3ac8d75ad5ffd5b4febe36def4e53c.zip |
Merge pull request #482 from 0xProject/feature/web3-types
Move common types out of web3 types
Diffstat (limited to 'packages/contracts')
-rw-r--r-- | packages/contracts/util/multi_sig_wrapper.ts | 5 | ||||
-rw-r--r-- | packages/contracts/util/types.ts | 6 |
2 files changed, 6 insertions, 5 deletions
diff --git a/packages/contracts/util/multi_sig_wrapper.ts b/packages/contracts/util/multi_sig_wrapper.ts index 3b83ccb7b..9f6dcec52 100644 --- a/packages/contracts/util/multi_sig_wrapper.ts +++ b/packages/contracts/util/multi_sig_wrapper.ts @@ -1,3 +1,4 @@ +import { AbiDefinition, MethodAbi } from '@0xproject/types'; import { BigNumber } from '@0xproject/utils'; import ABI = require('ethereumjs-abi'); import ethUtil = require('ethereumjs-util'); @@ -10,8 +11,8 @@ import { TransactionDataParams } from './types'; export class MultiSigWrapper { private _multiSig: MultiSigWalletContract; - public static encodeFnArgs(name: string, abi: Web3.AbiDefinition[], args: any[]) { - const abiEntity = _.find(abi, { name }) as Web3.MethodAbi; + public static encodeFnArgs(name: string, abi: AbiDefinition[], args: any[]) { + const abiEntity = _.find(abi, { name }) as MethodAbi; if (_.isUndefined(abiEntity)) { throw new Error(`Did not find abi entry for name: ${name}`); } diff --git a/packages/contracts/util/types.ts b/packages/contracts/util/types.ts index 61a19acb4..321084c42 100644 --- a/packages/contracts/util/types.ts +++ b/packages/contracts/util/types.ts @@ -1,5 +1,5 @@ +import { AbiDefinition, ContractAbi } from '@0xproject/types'; import { BigNumber } from '@0xproject/utils'; -import * as Web3 from 'web3'; export interface BalancesByOwner { [ownerAddress: string]: { @@ -51,7 +51,7 @@ export interface DefaultOrderParams { export interface TransactionDataParams { name: string; - abi: Web3.AbiDefinition[]; + abi: AbiDefinition[]; args: any[]; } @@ -105,7 +105,7 @@ export interface Artifact { contract_name: ContractName; networks: { [networkId: number]: { - abi: Web3.ContractAbi; + abi: ContractAbi; solc_version: string; keccak256: string; optimizer_enabled: number; |