@0x/order-utils
: Fix EP signature utils schema assertion.
This commit is contained in:
parent
6aa8f17ed5
commit
d31d646ecc
@ -17,6 +17,10 @@
|
||||
{
|
||||
"note": "Add `findTransformerNonce()` and `getTransformerAddress()` functions.",
|
||||
"pr": 2657
|
||||
},
|
||||
{
|
||||
"note": "Fix EP signature utils schema assertion.",
|
||||
"pr": 2657
|
||||
}
|
||||
]
|
||||
},
|
||||
|
@ -206,7 +206,9 @@ export const signatureUtils = {
|
||||
transaction: ExchangeProxyMetaTransaction,
|
||||
signerAddress: string,
|
||||
): Promise<SignedExchangeProxyMetaTransaction> {
|
||||
assert.doesConformToSchema('transaction', transaction, schemas.zeroExTransactionSchema, [schemas.hexSchema]);
|
||||
assert.doesConformToSchema('transaction', transaction, schemas.exchangeProxyMetaTransactionSchema, [
|
||||
schemas.hexSchema,
|
||||
]);
|
||||
try {
|
||||
const signedTransaction = await signatureUtils.ecSignTypedDataExchangeProxyMetaTransactionAsync(
|
||||
supportedProvider,
|
||||
@ -253,7 +255,9 @@ export const signatureUtils = {
|
||||
): Promise<SignedExchangeProxyMetaTransaction> {
|
||||
const provider = providerUtils.standardizeOrThrow(supportedProvider);
|
||||
assert.isETHAddressHex('signerAddress', signerAddress);
|
||||
assert.doesConformToSchema('transaction', transaction, schemas.zeroExTransactionSchema, [schemas.hexSchema]);
|
||||
assert.doesConformToSchema('transaction', transaction, schemas.exchangeProxyMetaTransactionSchema, [
|
||||
schemas.hexSchema,
|
||||
]);
|
||||
const web3Wrapper = new Web3Wrapper(provider);
|
||||
await assert.isSenderAddressAsync('signerAddress', signerAddress, web3Wrapper);
|
||||
const normalizedSignerAddress = signerAddress.toLowerCase();
|
||||
|
Loading…
x
Reference in New Issue
Block a user