Skip to content

Commit

Permalink
Fix loading state issue in account details
Browse files Browse the repository at this point in the history
  • Loading branch information
csillag committed Jul 3, 2023
1 parent bf0b898 commit 77fb72e
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/app/pages/AccountDetailsPage/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ export const AccountDetailsPage: FC = () => {

const scope = useRequiredScopeParam()
const address = useLoaderData() as string
const { account, isLoading, isError } = useAccount(scope, address)
const { token } = useTokenInfo(scope, address)
const { account, isLoading: isAcccountLoading, isError } = useAccount(scope, address)
const { token, isLoading: isTokenLoading } = useTokenInfo(scope, address)
const { totalCount: numberOfTokenTransfers } = useAccountTokenTransfers(scope, address)

const tokenPriceInfo = useTokenPrice(account?.ticker || Ticker.ROSE)
Expand All @@ -40,6 +40,7 @@ export const AccountDetailsPage: FC = () => {
const codeLink = useHref(`code#${contractCodeContainerId}`)

const showDetails = showTxs || showErc20
const isLoading = isAcccountLoading || isTokenLoading

return (
<PageLayout>
Expand Down

0 comments on commit 77fb72e

Please sign in to comment.