@defuse-protocol/intents-sdk 0.74.0 → 0.74.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -263,13 +263,11 @@ var OmniBridge = class {
263
263
  }
264
264
  async describeWithdrawal(args) {
265
265
  const transfer = (await this.omniBridgeAPI.getTransfer({ transactionHash: args.tx.hash }))[args.index];
266
- if (transfer == null || transfer.transfer_message == null) return { status: "pending" };
267
- const destinationChain = (0, _omni_bridge_core.getChain)(transfer.transfer_message.recipient);
266
+ if (transfer == null || transfer.recipient == null) return { status: "pending" };
267
+ const destinationChain = (0, _omni_bridge_core.getChain)(transfer.recipient);
268
268
  let txHash = null;
269
- if ((0, _omni_bridge_core.isEvmChain)(destinationChain)) txHash = transfer.finalised?.EVMLog?.transaction_hash;
270
- else if (destinationChain === _omni_bridge_core.ChainKind.Sol || destinationChain === _omni_bridge_core.ChainKind.Fogo) txHash = transfer.finalised?.Solana?.signature;
271
- else if (destinationChain === _omni_bridge_core.ChainKind.Btc) txHash = typeof window !== "undefined" ? transfer.utxo_transfer?.btc_pending_id : transfer.finalised?.UtxoLog?.transaction_hash;
272
- else if (destinationChain === _omni_bridge_core.ChainKind.Strk) txHash = transfer.finalised?.Starknet?.transaction_hash;
269
+ if ((0, _omni_bridge_core.isEvmChain)(destinationChain) || destinationChain === _omni_bridge_core.ChainKind.Sol || destinationChain === _omni_bridge_core.ChainKind.Fogo || destinationChain === _omni_bridge_core.ChainKind.Strk) txHash = transfer.finalised?.transaction_hash;
270
+ else if (require_omni_bridge_utils.isUtxoChain(destinationChain)) txHash = typeof window !== "undefined" ? transfer.utxo_meta?.pending_sign_id : transfer.finalised?.transaction_hash;
273
271
  else return {
274
272
  status: "completed",
275
273
  txHash: null
@@ -261,13 +261,11 @@ var OmniBridge = class {
261
261
  }
262
262
  async describeWithdrawal(args) {
263
263
  const transfer = (await this.omniBridgeAPI.getTransfer({ transactionHash: args.tx.hash }))[args.index];
264
- if (transfer == null || transfer.transfer_message == null) return { status: "pending" };
265
- const destinationChain = getChain(transfer.transfer_message.recipient);
264
+ if (transfer == null || transfer.recipient == null) return { status: "pending" };
265
+ const destinationChain = getChain(transfer.recipient);
266
266
  let txHash = null;
267
- if (isEvmChain(destinationChain)) txHash = transfer.finalised?.EVMLog?.transaction_hash;
268
- else if (destinationChain === ChainKind.Sol || destinationChain === ChainKind.Fogo) txHash = transfer.finalised?.Solana?.signature;
269
- else if (destinationChain === ChainKind.Btc) txHash = typeof window !== "undefined" ? transfer.utxo_transfer?.btc_pending_id : transfer.finalised?.UtxoLog?.transaction_hash;
270
- else if (destinationChain === ChainKind.Strk) txHash = transfer.finalised?.Starknet?.transaction_hash;
267
+ if (isEvmChain(destinationChain) || destinationChain === ChainKind.Sol || destinationChain === ChainKind.Fogo || destinationChain === ChainKind.Strk) txHash = transfer.finalised?.transaction_hash;
268
+ else if (isUtxoChain(destinationChain)) txHash = typeof window !== "undefined" ? transfer.utxo_meta?.pending_sign_id : transfer.finalised?.transaction_hash;
271
269
  else return {
272
270
  status: "completed",
273
271
  txHash: null
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@defuse-protocol/intents-sdk",
3
- "version": "0.74.0",
3
+ "version": "0.74.1",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "repository": {
@@ -38,8 +38,8 @@
38
38
  "@hot-labs/omni-sdk": "2.25.5",
39
39
  "@isaacs/ttlcache": "^1.0.0",
40
40
  "@lifeomic/attempt": "^3.0.0",
41
- "@omni-bridge/core": "0.9.1",
42
- "@omni-bridge/near": "0.9.1",
41
+ "@omni-bridge/core": "0.14.0",
42
+ "@omni-bridge/near": "0.14.0",
43
43
  "@noble/hashes": "^1.7.1",
44
44
  "@scure/base": "^1.0.0",
45
45
  "@solana/web3.js": "^1.0.0",