Merge pull request #274 from ArtemKolodko/fix_holders_count

Minor update holders count
pull/276/head
Artem 2 years ago committed by GitHub
commit d3d49c9689
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      src/pages/AddressPage/AddressDetails.tsx
  2. 3
      src/pages/AddressPage/index.tsx

@ -79,7 +79,7 @@ export function AddressDetailsDisplay(props: AddressDetailsProps) {
contractShardId contractShardId
}; };
if(holdersCount) { if(holdersCount !== undefined) {
data.holders = holdersCount data.holders = holdersCount
} }

@ -154,6 +154,9 @@ export function AddressPage() {
const getInventory = async () => { const getInventory = async () => {
try { try {
if (type === "erc721" || type === "erc1155") { if (type === "erc721" || type === "erc1155") {
if(type === "erc1155") {
setHoldersCount(0)
}
let items = type === "erc721" let items = type === "erc721"
? await getTokenERC721Assets([id]) ? await getTokenERC721Assets([id])
: await getTokenERC1155Assets([id]) : await getTokenERC1155Assets([id])

Loading…
Cancel
Save