update lockOrder types

This commit is contained in:
TheJuze
2024-01-23 16:52:22 +03:00
parent aac63a6930
commit a2cdadfa09
5 changed files with 5 additions and 9 deletions

4
package-lock.json generated
View File

@@ -1,12 +1,12 @@
{ {
"name": "@orionprotocol/sdk", "name": "@orionprotocol/sdk",
"version": "0.20.45", "version": "0.20.42-rc9",
"lockfileVersion": 2, "lockfileVersion": 2,
"requires": true, "requires": true,
"packages": { "packages": {
"": { "": {
"name": "@orionprotocol/sdk", "name": "@orionprotocol/sdk",
"version": "0.20.45", "version": "0.20.42-rc9",
"hasInstallScript": true, "hasInstallScript": true,
"license": "ISC", "license": "ISC",
"dependencies": { "dependencies": {

View File

@@ -1,6 +1,6 @@
{ {
"name": "@orionprotocol/sdk", "name": "@orionprotocol/sdk",
"version": "0.20.42-rc8", "version": "0.20.42-rc9",
"description": "Orion Protocol SDK", "description": "Orion Protocol SDK",
"main": "./lib/index.cjs", "main": "./lib/index.cjs",
"module": "./lib/index.js", "module": "./lib/index.js",

View File

@@ -10,7 +10,7 @@ import {
LOCKATOMIC_GAS_LIMIT, LOCKATOMIC_GAS_LIMIT,
REDEEMATOMIC_GAS_LIMIT, REDEEMATOMIC_GAS_LIMIT,
WITHDRAW_GAS_LIMIT WITHDRAW_GAS_LIMIT
} from '../../constants/index.js'; } from '../../constants';
import getNativeCryptocurrencyName from '../../utils/getNativeCryptocurrencyName.js'; import getNativeCryptocurrencyName from '../../utils/getNativeCryptocurrencyName.js';
import { denormalizeNumber, generateSecret, normalizeNumber, toUpperCase } from '../../utils/index.js'; import { denormalizeNumber, generateSecret, normalizeNumber, toUpperCase } from '../../utils/index.js';
import type { SupportedChainId } from '../../types.js'; import type { SupportedChainId } from '../../types.js';

View File

@@ -14,7 +14,6 @@ export type LockOrderProps = {
senderAddress: string // broker senderAddress: string // broker
asset: string asset: string
amount: ethers.BigNumberish amount: ethers.BigNumberish
sign: string // подпись юзера
signer: ethers.Signer signer: ethers.Signer
chainId: SupportedChainId chainId: SupportedChainId
targetChainId: SupportedChainId targetChainId: SupportedChainId
@@ -23,11 +22,10 @@ export type LockOrderProps = {
export const signLockOrder = async ({ export const signLockOrder = async ({
userAddress, userAddress,
senderAddress, senderAddress,
sign,
amount, amount,
chainId,
targetChainId, targetChainId,
asset, asset,
chainId,
signer signer
}: LockOrderProps) => { }: LockOrderProps) => {
const nonce = Date.now(); const nonce = Date.now();
@@ -43,7 +41,6 @@ export const signLockOrder = async ({
amount, amount,
targetChainId, targetChainId,
secretHash, secretHash,
sign
}; };
// eslint-disable-next-line @typescript-eslint/consistent-type-assertions // eslint-disable-next-line @typescript-eslint/consistent-type-assertions

View File

@@ -64,7 +64,6 @@ export type LockOrder = {
amount: ethers.BigNumberish // uint64 amount: ethers.BigNumberish // uint64
targetChainId: SupportedChainId // uint64 targetChainId: SupportedChainId // uint64
secretHash: string // uint64 secretHash: string // uint64
sign: string // uint64 // подпись юзера
} }
type SignedOrderAdditionalProps = { type SignedOrderAdditionalProps = {