diff options
author | Fabio Berger <me@fabioberger.com> | 2017-11-10 06:18:30 +0800 |
---|---|---|
committer | Fabio Berger <me@fabioberger.com> | 2017-11-10 06:18:30 +0800 |
commit | 02cc3f911624d31d581d4637d17ad2fa6fd95bc6 (patch) | |
tree | 33925b79c035292e3956adf760cb31fad77896e8 /src/order_watcher | |
parent | 62861d1e1315a14e955b30a45db05e7907b0d22d (diff) | |
download | dexon-sol-tools-02cc3f911624d31d581d4637d17ad2fa6fd95bc6.tar dexon-sol-tools-02cc3f911624d31d581d4637d17ad2fa6fd95bc6.tar.gz dexon-sol-tools-02cc3f911624d31d581d4637d17ad2fa6fd95bc6.tar.bz2 dexon-sol-tools-02cc3f911624d31d581d4637d17ad2fa6fd95bc6.tar.lz dexon-sol-tools-02cc3f911624d31d581d4637d17ad2fa6fd95bc6.tar.xz dexon-sol-tools-02cc3f911624d31d581d4637d17ad2fa6fd95bc6.tar.zst dexon-sol-tools-02cc3f911624d31d581d4637d17ad2fa6fd95bc6.zip |
Create assert.isValidSignature method and use it in `addOrder`
Diffstat (limited to 'src/order_watcher')
-rw-r--r-- | src/order_watcher/order_state_watcher.ts | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/order_watcher/order_state_watcher.ts b/src/order_watcher/order_state_watcher.ts index 14b5b6cf9..6d56293ef 100644 --- a/src/order_watcher/order_state_watcher.ts +++ b/src/order_watcher/order_state_watcher.ts @@ -60,6 +60,7 @@ export class OrderStateWatcher { public addOrder(signedOrder: SignedOrder): void { assert.doesConformToSchema('signedOrder', signedOrder, schemas.signedOrderSchema); const orderHash = ZeroEx.getOrderHashHex(signedOrder); + assert.isValidSignature(orderHash, signedOrder.ecSignature, signedOrder.maker); this._orders[orderHash] = signedOrder; this.addToDependentOrderHashes(signedOrder, orderHash); } |