Commit ad766958 authored by isstuev's avatar isstuev

type fixes

parent a9cbaf92
......@@ -120,7 +120,7 @@ const TokenPageContent = () => {
}, [ tokenQuery.data, tokenQuery.isPlaceholderData ]);
const hasData = (tokenQuery.data && !tokenQuery.isPlaceholderData) && (contractQuery.data && !contractQuery.isPlaceholderData);
const hasInventoryTab = Boolean(tokenQuery.data?.type) && NFT_TOKEN_TYPE_IDS.includes(tokenQuery.data.type);
const hasInventoryTab = tokenQuery.data?.type && NFT_TOKEN_TYPE_IDS.includes(tokenQuery.data.type);
const transfersQuery = useQueryWithPages({
resourceName: 'token_transfers',
......
......@@ -35,7 +35,7 @@ const TokenTransferListItem = ({
isLoading,
}: Props) => {
const timeAgo = useTimeAgoIncrement(timestamp, enableTimeIncrement);
const { usd, valueStr } = 'value' in total ? getCurrencyValue({
const { usd, valueStr } = 'value' in total && total.value !== null ? getCurrencyValue({
value: total.value,
exchangeRate: token.exchange_rate,
accuracy: 8,
......
......@@ -34,7 +34,7 @@ const TokenTransferTableItem = ({
isLoading,
}: Props) => {
const timeAgo = useTimeAgoIncrement(timestamp, enableTimeIncrement);
const { usd, valueStr } = 'value' in total ? getCurrencyValue({
const { usd, valueStr } = 'value' in total && total.value !== null ? getCurrencyValue({
value: total.value,
exchangeRate: token.exchange_rate,
accuracy: 8,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment