diff options
author | Fabio Berger <me@fabioberger.com> | 2017-11-11 23:21:59 +0800 |
---|---|---|
committer | Fabio Berger <me@fabioberger.com> | 2017-11-11 23:21:59 +0800 |
commit | d61f34ec125884ff1c17f41dbc8c844b866390f5 (patch) | |
tree | 52cf577402f77fb1cdf29c4ffdf339d077f03864 | |
parent | 252fdd03d718173a6c1ffa75c3b18d6f1a7d051c (diff) | |
download | dexon-sol-tools-d61f34ec125884ff1c17f41dbc8c844b866390f5.tar dexon-sol-tools-d61f34ec125884ff1c17f41dbc8c844b866390f5.tar.gz dexon-sol-tools-d61f34ec125884ff1c17f41dbc8c844b866390f5.tar.bz2 dexon-sol-tools-d61f34ec125884ff1c17f41dbc8c844b866390f5.tar.lz dexon-sol-tools-d61f34ec125884ff1c17f41dbc8c844b866390f5.tar.xz dexon-sol-tools-d61f34ec125884ff1c17f41dbc8c844b866390f5.tar.zst dexon-sol-tools-d61f34ec125884ff1c17f41dbc8c844b866390f5.zip |
Declare OnOrderStateChangeCallback as either sync or async
-rw-r--r-- | src/types.ts | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/types.ts b/src/types.ts index 13867dac8..411ff3bfd 100644 --- a/src/types.ts +++ b/src/types.ts @@ -508,6 +508,6 @@ export interface OrderStateInvalid { export type OrderState = OrderStateValid|OrderStateInvalid; -export type OnOrderStateChangeCallback = ( - orderState: OrderState, -) => void; +export type OnOrderStateChangeCallbackSync = (orderState: OrderState) => void; +export type OnOrderStateChangeCallbackAsync = (orderState: OrderState) => Promise<void>; +export type OnOrderStateChangeCallback = OnOrderStateChangeCallbackAsync|OnOrderStateChangeCallbackSync; |