aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorLeonid Logvinov <logvinov.leon@gmail.com>2017-07-05 08:33:35 +0800
committerLeonid Logvinov <logvinov.leon@gmail.com>2017-07-05 08:33:35 +0800
commit464c16be73bddce1ed675f642937b164f7add9d8 (patch)
tree4abf982c659ce8e51d561812dc30091ae37f6d88 /src
parent4d522db4747004ffd6471fdacaa61494267a66a8 (diff)
downloaddexon-sol-tools-464c16be73bddce1ed675f642937b164f7add9d8.tar
dexon-sol-tools-464c16be73bddce1ed675f642937b164f7add9d8.tar.gz
dexon-sol-tools-464c16be73bddce1ed675f642937b164f7add9d8.tar.bz2
dexon-sol-tools-464c16be73bddce1ed675f642937b164f7add9d8.tar.lz
dexon-sol-tools-464c16be73bddce1ed675f642937b164f7add9d8.tar.xz
dexon-sol-tools-464c16be73bddce1ed675f642937b164f7add9d8.tar.zst
dexon-sol-tools-464c16be73bddce1ed675f642937b164f7add9d8.zip
move order hash schema to a separate file
Diffstat (limited to 'src')
-rw-r--r--src/0x.ts3
-rw-r--r--src/contract_wrappers/exchange_wrapper.ts3
-rw-r--r--src/schemas/order_schemas.ts6
-rw-r--r--src/utils/schema_validator.ts3
4 files changed, 6 insertions, 9 deletions
diff --git a/src/0x.ts b/src/0x.ts
index d790ca38e..49bd31f2d 100644
--- a/src/0x.ts
+++ b/src/0x.ts
@@ -17,7 +17,8 @@ import {ecSignatureSchema} from './schemas/ec_signature_schema';
import {TokenWrapper} from './contract_wrappers/token_wrapper';
import {ProxyWrapper} from './contract_wrappers/proxy_wrapper';
import {ECSignature, ZeroExError, Order, SignedOrder, Web3Provider} from './types';
-import {orderSchema, orderHashSchema} from './schemas/order_schemas';
+import {orderHashSchema} from './schemas/order_hash_schema';
+import {orderSchema} from './schemas/order_schemas';
import {SchemaValidator} from './utils/schema_validator';
// Customize our BigNumber instances
diff --git a/src/contract_wrappers/exchange_wrapper.ts b/src/contract_wrappers/exchange_wrapper.ts
index 72f00ee91..5a2da4a98 100644
--- a/src/contract_wrappers/exchange_wrapper.ts
+++ b/src/contract_wrappers/exchange_wrapper.ts
@@ -45,7 +45,8 @@ import {indexFilterValuesSchema} from '../schemas/index_filter_values_schema';
import {orderFillRequestsSchema} from '../schemas/order_fill_requests_schema';
import {orderCancellationRequestsSchema} from '../schemas/order_cancel_schema';
import {orderFillOrKillRequestsSchema} from '../schemas/order_fill_or_kill_requests_schema';
-import {signedOrderSchema, orderSchema, orderHashSchema} from '../schemas/order_schemas';
+import {orderHashSchema} from '../schemas/order_hash_schema';
+import {signedOrderSchema, orderSchema} from '../schemas/order_schemas';
import {constants} from '../utils/constants';
import {TokenWrapper} from './token_wrapper';
import {decorators} from '../utils/decorators';
diff --git a/src/schemas/order_schemas.ts b/src/schemas/order_schemas.ts
index b5e4a72bb..c346687b5 100644
--- a/src/schemas/order_schemas.ts
+++ b/src/schemas/order_schemas.ts
@@ -25,12 +25,6 @@ export const orderSchema = {
type: 'object',
};
-export const orderHashSchema = {
- id: '/orderHashSchema',
- type: 'string',
- pattern: '^0x[0-9a-fA-F]{64}$',
-};
-
export const signedOrderSchema = {
id: '/signedOrderSchema',
allOf: [
diff --git a/src/utils/schema_validator.ts b/src/utils/schema_validator.ts
index 20c160068..58450ff20 100644
--- a/src/utils/schema_validator.ts
+++ b/src/utils/schema_validator.ts
@@ -1,6 +1,7 @@
import {Validator, ValidatorResult, Schema} from 'jsonschema';
import {ecSignatureSchema, ecSignatureParameterSchema} from '../schemas/ec_signature_schema';
-import {orderSchema, signedOrderSchema, orderHashSchema} from '../schemas/order_schemas';
+import {orderHashSchema} from '../schemas/order_hash_schema';
+import {orderSchema, signedOrderSchema} from '../schemas/order_schemas';
import {addressSchema, numberSchema} from '../schemas/basic_type_schemas';
import {tokenSchema} from '../schemas/token_schema';
import {subscriptionOptsSchema, blockParamSchema} from '../schemas/subscription_opts_schema';