aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLeonid Logvinov <logvinov.leon@gmail.com>2017-07-26 21:15:57 +0800
committerLeonid Logvinov <logvinov.leon@gmail.com>2018-01-10 18:24:34 +0800
commit80291930f040f4ed0cfbf5eebf885c374ff7905f (patch)
treef05c674fddb907070963d9711a46f1aa2a5a75d4
parentcf8678b97995d341aaf76345b0a4ab98163b6de2 (diff)
downloaddexon-sol-tools-80291930f040f4ed0cfbf5eebf885c374ff7905f.tar
dexon-sol-tools-80291930f040f4ed0cfbf5eebf885c374ff7905f.tar.gz
dexon-sol-tools-80291930f040f4ed0cfbf5eebf885c374ff7905f.tar.bz2
dexon-sol-tools-80291930f040f4ed0cfbf5eebf885c374ff7905f.tar.lz
dexon-sol-tools-80291930f040f4ed0cfbf5eebf885c374ff7905f.tar.xz
dexon-sol-tools-80291930f040f4ed0cfbf5eebf885c374ff7905f.tar.zst
dexon-sol-tools-80291930f040f4ed0cfbf5eebf885c374ff7905f.zip
Make error types consistent
-rw-r--r--packages/web3-typescript-typings/index.d.ts10
1 files changed, 5 insertions, 5 deletions
diff --git a/packages/web3-typescript-typings/index.d.ts b/packages/web3-typescript-typings/index.d.ts
index 4bd6bf371..0b17a50c6 100644
--- a/packages/web3-typescript-typings/index.d.ts
+++ b/packages/web3-typescript-typings/index.d.ts
@@ -90,7 +90,7 @@ declare module 'web3' {
interface FilterResult {
get(callback: () => void): void;
- watch<A>(callback: (error: string|null, result: SolidityEvent<A>) => void): void;
+ watch<A>(callback: (err: Error, result: SolidityEvent<A>) => void): void;
stopWatching(callback: () => void): void;
}
@@ -118,7 +118,7 @@ declare module 'web3' {
getSyncing(cd: (err: Error, syncing: Web3.SyncingResult) => void): void;
isSyncing(cb: (err: Error, isSyncing: boolean, syncingState: Web3.SyncingState) => void): Web3.IsSyncing;
compile: {
- solidity(sourceString: string, cb?: (err: any, result: any) => void): object,
+ solidity(sourceString: string, cb?: (err: Error, result: any) => void): object,
}
getBlock(hashStringOrBlockNumber: string|Web3.BlockParam): Web3.BlockWithoutTransactionData;
@@ -151,15 +151,15 @@ declare module 'web3' {
// TODO block param
getBalance(addressHexString: string): BigNumber.BigNumber;
- getBalance(addressHexString: string, callback: (err: any, result: BigNumber.BigNumber) => void): void;
+ getBalance(addressHexString: string, callback: (err: Error, result: BigNumber.BigNumber) => void): void;
// TODO block param
getStorageAt(address: string, position: number): string;
- getStorageAt(address: string, position: number, callback: (err: any, storage: string) => void): void;
+ getStorageAt(address: string, position: number, callback: (err: Error, storage: string) => void): void;
// TODO block param
getCode(addressHexString: string): string;
- getCode(addressHexString: string, callback: (err: any, code: string) => void): void;
+ getCode(addressHexString: string, callback: (err: Error, code: string) => void): void;
filter(value: string|Web3.FilterObject): Web3.FilterResult;