diff options
Diffstat (limited to 'packages/order-utils')
-rw-r--r-- | packages/order-utils/CHANGELOG.json | 6 | ||||
-rw-r--r-- | packages/order-utils/package.json | 2 | ||||
-rw-r--r-- | packages/order-utils/src/order_validation_utils.ts | 6 |
3 files changed, 9 insertions, 5 deletions
diff --git a/packages/order-utils/CHANGELOG.json b/packages/order-utils/CHANGELOG.json index a1f199793..199ce2173 100644 --- a/packages/order-utils/CHANGELOG.json +++ b/packages/order-utils/CHANGELOG.json @@ -1,8 +1,12 @@ [ { - "version": "0.1.0", + "version": "1.0.0", "changes": [ { + "note": "Refactor to work with V2 of 0x protocol", + "pr": 636 + }, + { "note": "Export parseECSignature method", "pr": 684 } diff --git a/packages/order-utils/package.json b/packages/order-utils/package.json index e3c81de44..97b08c3d3 100644 --- a/packages/order-utils/package.json +++ b/packages/order-utils/package.json @@ -82,7 +82,7 @@ "@0xproject/web3-wrapper": "^0.7.1", "@types/node": "^8.0.53", "bn.js": "^4.11.8", - "ethereum-types": "^0.0.1", + "ethereum-types": "^0.0.2", "ethereumjs-abi": "^0.6.4", "ethereumjs-util": "^5.1.1", "ethers": "3.0.22", diff --git a/packages/order-utils/src/order_validation_utils.ts b/packages/order-utils/src/order_validation_utils.ts index 54428f77d..94df3ef82 100644 --- a/packages/order-utils/src/order_validation_utils.ts +++ b/packages/order-utils/src/order_validation_utils.ts @@ -140,12 +140,12 @@ export class OrderValidationUtils { takerAddress: string, zrxAssetData: string, ): Promise<BigNumber> { - if (fillTakerAssetAmount.eq(0)) { - throw new Error(RevertReason.InvalidTakerAmount); - } if (signedOrder.makerAssetAmount.eq(0) || signedOrder.takerAssetAmount.eq(0)) { throw new Error(RevertReason.OrderUnfillable); } + if (fillTakerAssetAmount.eq(0)) { + throw new Error(RevertReason.InvalidTakerAmount); + } const orderHash = orderHashUtils.getOrderHashHex(signedOrder); const isValid = await isValidSignatureAsync( provider, |