mirror of
https://github.com/orionprotocol/sdk.git
synced 2026-03-15 14:42:38 +03:00
🗿
This commit is contained in:
4
package-lock.json
generated
4
package-lock.json
generated
@@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "@orionprotocol/sdk",
|
||||
"version": "0.22.0-rc5",
|
||||
"version": "0.22.0-rc6",
|
||||
"lockfileVersion": 2,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "@orionprotocol/sdk",
|
||||
"version": "0.22.0-rc5",
|
||||
"version": "0.22.0-rc6",
|
||||
"hasInstallScript": true,
|
||||
"license": "ISC",
|
||||
"dependencies": {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@orionprotocol/sdk",
|
||||
"version": "0.22.0-rc5",
|
||||
"version": "0.22.0-rc6",
|
||||
"description": "Orion Protocol SDK",
|
||||
"main": "./lib/index.cjs",
|
||||
"module": "./lib/index.js",
|
||||
|
||||
@@ -37,7 +37,7 @@ export const signOrder = async ({
|
||||
targetChainId,
|
||||
chainId,
|
||||
price
|
||||
}: SignOrderProps) => {
|
||||
}: SignOrderProps): Promise<SignedOrder> => {
|
||||
const nonce = Date.now();
|
||||
const expiration = nonce + DEFAULT_EXPIRATION;
|
||||
|
||||
@@ -131,7 +131,14 @@ export const signOrder = async ({
|
||||
...order,
|
||||
id: limitOrderHash, // TODO: change to orderHash
|
||||
signature: fixedSignature,
|
||||
...(isCrossChain ? { secret, secretHash, targetChainId: Number(targetChainId), lockOrderExpiration: expiration } : {})
|
||||
...(isCrossChain
|
||||
? {
|
||||
secret,
|
||||
secretHash,
|
||||
targetChainId: Number(targetChainId),
|
||||
lockOrderExpiration: expiration
|
||||
}
|
||||
: {})
|
||||
};
|
||||
return signedOrder;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user