diff options
author | Fabio Berger <me@fabioberger.com> | 2018-06-08 00:10:56 +0800 |
---|---|---|
committer | Fabio Berger <me@fabioberger.com> | 2018-06-08 00:10:56 +0800 |
commit | dee0fec9e9521712d11f1f040ae1264c41badaba (patch) | |
tree | d62b98046277877125c476fadf0b5a7dd4f052a2 /packages | |
parent | 73cc2a140c778a5396c2766562a3fc648337e18a (diff) | |
download | dexon-sol-tools-dee0fec9e9521712d11f1f040ae1264c41badaba.tar.gz dexon-sol-tools-dee0fec9e9521712d11f1f040ae1264c41badaba.tar.zst dexon-sol-tools-dee0fec9e9521712d11f1f040ae1264c41badaba.zip |
Revert to returning orderState on invalid order
Diffstat (limited to 'packages')
-rw-r--r-- | packages/order-utils/src/order_state_utils.ts | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/packages/order-utils/src/order_state_utils.ts b/packages/order-utils/src/order_state_utils.ts index 7636372f8..ef868e60f 100644 --- a/packages/order-utils/src/order_state_utils.ts +++ b/packages/order-utils/src/order_state_utils.ts @@ -69,7 +69,12 @@ export class OrderStateUtils { }; return orderState; } catch (err) { - throw err; + const orderState: OrderStateInvalid = { + isValid: false, + orderHash, + error: err.message, + }; + return orderState; } } public async getOrderRelevantStateAsync(signedOrder: SignedOrder): Promise<OrderRelevantState> { |