From ab62b12d0518a8da42ddb8bb787c76584bf60848 Mon Sep 17 00:00:00 2001 From: cryptickoan Date: Wed, 13 Apr 2022 13:26:11 -0600 Subject: [PATCH] oracle identity query key updated to avoid using cache --- .../pages/Fuse/FusePoolInfoPage.tsx | 40 ++++++++++--------- src/hooks/fuse/useOracleData.ts | 2 +- 2 files changed, 22 insertions(+), 20 deletions(-) diff --git a/src/components/pages/Fuse/FusePoolInfoPage.tsx b/src/components/pages/Fuse/FusePoolInfoPage.tsx index b1d4a890..23ceec8f 100644 --- a/src/components/pages/Fuse/FusePoolInfoPage.tsx +++ b/src/components/pages/Fuse/FusePoolInfoPage.tsx @@ -390,8 +390,9 @@ const AssetAndOtherInfo = ({ assets, poolOracle, tokensData }: { assets: USDPric const oracleIdentity = useIdentifyOracle( selectedAsset.oracle, poolOracle, - selectedAsset.underlyingToken, - ); + selectedAsset.underlyingToken + ) + // Link to MPO if asset is ETH const oracleAddress = (selectedAsset.underlyingToken === ETH_TOKEN_DATA.address || selectedAsset.oracle === ETH_TOKEN_DATA.address) @@ -511,23 +512,24 @@ const AssetAndOtherInfo = ({ assets, poolOracle, tokensData }: { assets: USDPric crossAxisAlignment="center" captionFirst={true} /> - - - - - - + { !oracleIdentity ? : + + + + + + } { const { fuse } = useRari(); - const { data } = useQuery("Identifying Oracle " + oracleAddr, async () => { + const { data } = useQuery("Identifying Oracle " + tokenAddr, async () => { if (tokenAddr && tokenAddr === ETH_TOKEN_DATA.address) return "MasterPriceOracle";