Fix orderSchema

This commit is contained in:
Leonid Logvinov 2017-05-30 12:56:11 +02:00
parent 766d46041e
commit 0b81cd9d78
No known key found for this signature in database
GPG Key ID: 0DD294BFDE8C95D4

View File

@ -6,7 +6,8 @@ export const addressSchema = {
export const numberSchema = { export const numberSchema = {
id: '/numberSchema', id: '/numberSchema',
type: 'number', type: 'string',
format: '\d+(\.\d+)?',
}; };
export const orderSchema = { export const orderSchema = {
@ -25,13 +26,12 @@ export const orderSchema = {
takerTokenAddress: {$ref: '/addressSchema'}, takerTokenAddress: {$ref: '/addressSchema'},
salt: {$ref: '/numberSchema'}, salt: {$ref: '/numberSchema'},
fillAmount: {$ref: '/numberSchema'},
feeRecipient: {$ref: '/addressSchema'}, feeRecipient: {$ref: '/addressSchema'},
expirationUnixTimestampSec: {$ref: '/numberSchema'}, expirationUnixTimestampSec: {$ref: '/numberSchema'},
}, },
required: [ required: [
'maker', /*'taker',*/ 'makerFee', 'takerFee', 'makerTokenAmount', 'takerTokenAmount', 'maker', /*'taker',*/ 'makerFee', 'takerFee', 'makerTokenAmount', 'takerTokenAmount',
'salt', 'fillAmount', 'feeRecipient', 'expirationUnixTimestampSec', 'salt', 'feeRecipient', 'expirationUnixTimestampSec',
], ],
type: 'object', type: 'object',
}; };
@ -42,7 +42,7 @@ export const signedOrderSchema = {
{ $ref: '/orderSchema' }, { $ref: '/orderSchema' },
{ {
properties: { properties: {
ecSignature: {$ref: '/addressSchema'}, ecSignature: {$ref: '/ECSignature'},
}, },
required: ['ecSignature'], required: ['ecSignature'],
}, },