aboutsummaryrefslogtreecommitdiffstats
path: root/packages/0x.js/src/contract_wrappers
diff options
context:
space:
mode:
authorLeonid Logvinov <logvinov.leon@gmail.com>2017-12-19 23:22:57 +0800
committerLeonid Logvinov <logvinov.leon@gmail.com>2017-12-19 23:22:57 +0800
commit75f637bd756fd7d4480792ead7bd86dd8326e622 (patch)
tree000fd6a09f2fcaedd640a8580ba8f8c90185958e /packages/0x.js/src/contract_wrappers
parent1316a2dd2a8971771f750d8a7f457212daad520b (diff)
downloaddexon-sol-tools-75f637bd756fd7d4480792ead7bd86dd8326e622.tar
dexon-sol-tools-75f637bd756fd7d4480792ead7bd86dd8326e622.tar.gz
dexon-sol-tools-75f637bd756fd7d4480792ead7bd86dd8326e622.tar.bz2
dexon-sol-tools-75f637bd756fd7d4480792ead7bd86dd8326e622.tar.lz
dexon-sol-tools-75f637bd756fd7d4480792ead7bd86dd8326e622.tar.xz
dexon-sol-tools-75f637bd756fd7d4480792ead7bd86dd8326e622.tar.zst
dexon-sol-tools-75f637bd756fd7d4480792ead7bd86dd8326e622.zip
Throw a better error message when taker is null|undefined or anything but not a string
Diffstat (limited to 'packages/0x.js/src/contract_wrappers')
-rw-r--r--packages/0x.js/src/contract_wrappers/exchange_wrapper.ts14
1 files changed, 7 insertions, 7 deletions
diff --git a/packages/0x.js/src/contract_wrappers/exchange_wrapper.ts b/packages/0x.js/src/contract_wrappers/exchange_wrapper.ts
index df793aa06..70d2be7e9 100644
--- a/packages/0x.js/src/contract_wrappers/exchange_wrapper.ts
+++ b/packages/0x.js/src/contract_wrappers/exchange_wrapper.ts
@@ -162,7 +162,7 @@ export class ExchangeWrapper extends ContractWrapper {
* @param orderTransactionOpts Optional arguments this method accepts.
* @return Transaction hash.
*/
- @decorators.contractCallErrorHandler
+ @decorators.asyncZeroExErrorHandler
public async fillOrderAsync(signedOrder: SignedOrder, fillTakerTokenAmount: BigNumber,
shouldThrowOnInsufficientBalanceOrAllowance: boolean,
takerAddress: string,
@@ -218,7 +218,7 @@ export class ExchangeWrapper extends ContractWrapper {
* @param orderTransactionOpts Optional arguments this method accepts.
* @return Transaction hash.
*/
- @decorators.contractCallErrorHandler
+ @decorators.asyncZeroExErrorHandler
public async fillOrdersUpToAsync(signedOrders: SignedOrder[], fillTakerTokenAmount: BigNumber,
shouldThrowOnInsufficientBalanceOrAllowance: boolean,
takerAddress: string,
@@ -299,7 +299,7 @@ export class ExchangeWrapper extends ContractWrapper {
* @param orderTransactionOpts Optional arguments this method accepts.
* @return Transaction hash.
*/
- @decorators.contractCallErrorHandler
+ @decorators.asyncZeroExErrorHandler
public async batchFillOrdersAsync(orderFillRequests: OrderFillRequest[],
shouldThrowOnInsufficientBalanceOrAllowance: boolean,
takerAddress: string,
@@ -372,7 +372,7 @@ export class ExchangeWrapper extends ContractWrapper {
* @param orderTransactionOpts Optional arguments this method accepts.
* @return Transaction hash.
*/
- @decorators.contractCallErrorHandler
+ @decorators.asyncZeroExErrorHandler
public async fillOrKillOrderAsync(signedOrder: SignedOrder, fillTakerTokenAmount: BigNumber,
takerAddress: string,
orderTransactionOpts: OrderTransactionOpts = {}): Promise<string> {
@@ -417,7 +417,7 @@ export class ExchangeWrapper extends ContractWrapper {
* @param orderTransactionOpts Optional arguments this method accepts.
* @return Transaction hash.
*/
- @decorators.contractCallErrorHandler
+ @decorators.asyncZeroExErrorHandler
public async batchFillOrKillAsync(orderFillRequests: OrderFillRequest[],
takerAddress: string,
orderTransactionOpts: OrderTransactionOpts = {}): Promise<string> {
@@ -485,7 +485,7 @@ export class ExchangeWrapper extends ContractWrapper {
* @param transactionOpts Optional arguments this method accepts.
* @return Transaction hash.
*/
- @decorators.contractCallErrorHandler
+ @decorators.asyncZeroExErrorHandler
public async cancelOrderAsync(order: Order|SignedOrder,
cancelTakerTokenAmount: BigNumber,
orderTransactionOpts: OrderTransactionOpts = {}): Promise<string> {
@@ -526,7 +526,7 @@ export class ExchangeWrapper extends ContractWrapper {
* @param transactionOpts Optional arguments this method accepts.
* @return Transaction hash.
*/
- @decorators.contractCallErrorHandler
+ @decorators.asyncZeroExErrorHandler
public async batchCancelOrdersAsync(orderCancellationRequests: OrderCancellationRequest[],
orderTransactionOpts: OrderTransactionOpts = {}): Promise<string> {
assert.doesConformToSchema('orderCancellationRequests', orderCancellationRequests,