From 4ddaf547fd3fc8d2d5a4f07126e4fba120b1381a Mon Sep 17 00:00:00 2001 From: Hau Nguyen Van Date: Sun, 5 Jan 2025 14:23:17 +0700 Subject: [PATCH] update common --- packages/oraidex-common/package.json | 2 +- packages/oraidex-common/src/helper.ts | 4 +++- yarn.lock | 25 +++++++++++++++++++++++++ 3 files changed, 29 insertions(+), 2 deletions(-) diff --git a/packages/oraidex-common/package.json b/packages/oraidex-common/package.json index c736cae6..482e4f41 100644 --- a/packages/oraidex-common/package.json +++ b/packages/oraidex-common/package.json @@ -1,6 +1,6 @@ { "name": "@oraichain/oraidex-common", - "version": "2.0.8", + "version": "2.0.9", "main": "./build/index.js", "module": "./build/index.js", "types": "./build/index.d.ts", diff --git a/packages/oraidex-common/src/helper.ts b/packages/oraidex-common/src/helper.ts index b3a9af9c..e000218f 100644 --- a/packages/oraidex-common/src/helper.ts +++ b/packages/oraidex-common/src/helper.ts @@ -274,7 +274,9 @@ export const getTokenOnOraichain = (coingeckoId: CoinGeckoId, oraichainTokens: T if (!filterOraichainToken.length) return undefined; if (filterOraichainToken.length === 1) return filterOraichainToken[0]; - const oraichainToken = filterOraichainToken.find((token) => (isNative ? !token.evmDenoms : token.evmDenoms)); + const oraichainToken = filterOraichainToken.find((token) => + isNative ? !token.contractAddress : token.contractAddress + ); return oraichainToken; }; diff --git a/yarn.lock b/yarn.lock index cd9ef292..3357c4bb 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3807,6 +3807,31 @@ resolved "https://registry.yarnpkg.com/@oraichain/immutable/-/immutable-4.3.9.tgz#ff8d5a7b39b5b01f3f72a902cffbfea32ccb20c3" integrity sha512-INpHnhL970OCkR7I71Kssb2aLl2l4Y/x8W6FlyRO0KmC8GHjxc/hlNB1t44BiI7lkOYmcWMRQoC8dwParsp1RQ== +"@oraichain/oraidex-common@2.0.8": + version "2.0.8" + resolved "https://registry.yarnpkg.com/@oraichain/oraidex-common/-/oraidex-common-2.0.8.tgz#4e2682bc03d909e4e02e6a83fe348f90b78b7ee0" + integrity sha512-6LKwgkwsaN5KxwlTngNyVqeGWqO5xc2H0FuebLr3hA1O72gICMmmqD3/pCB2c7nITQucuu59aX07frnHamgkAQ== + dependencies: + "@cosmjs/amino" "^0.32.4" + "@cosmjs/cosmwasm-stargate" "^0.32.4" + "@cosmjs/crypto" "^0.32.4" + "@cosmjs/proto-signing" "^0.32.4" + "@cosmjs/stargate" "^0.32.4" + "@cosmjs/tendermint-rpc" "^0.32.4" + "@ethersproject/providers" "^5.0.10" + "@injectivelabs/sdk-ts" "1.12.1" + "@keplr-wallet/types" "^0.11.38" + "@oraichain/common" "1.2.8" + "@oraichain/oraidex-contracts-sdk" latest + "@ton/core" "0.56.3" + "@ton/crypto" "3.3.0" + axios "1.7.2" + axios-extensions "3.1.7" + bignumber.js "^9.1.2" + cosmjs-types "^0.9.0" + ethers "^5.0.15" + tronweb "6.0.0-beta.4" + "@oraichain/oraidex-common@^1.1.34": version "1.1.34" resolved "https://registry.yarnpkg.com/@oraichain/oraidex-common/-/oraidex-common-1.1.34.tgz#257d25408450c438dc2bf0870fa8de9125af92ed"