fix(community): Owner token / Token Master token not visible in community settings (#15983)

Fixes #15830

followup task #15981 - reload tokens when app goes back online
This commit is contained in:
Andrey Bocharnikov 2024-08-06 01:20:04 +07:00 committed by GitHub
parent 6aa6746de2
commit 8d4a2ec983
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 11 additions and 8 deletions

View File

@ -378,16 +378,19 @@ proc getCommunityTokensDetailsTaskArg(argEncoded: string) {.gcsafe, nimcall.} =
var destructedAmount = "0" var destructedAmount = "0"
if tokenDto.deployState == DeployState.Deployed: if tokenDto.deployState == DeployState.Deployed:
remainingSupply = try:
if tokenDto.infiniteSupply: remainingSupply =
"0" if tokenDto.infiniteSupply:
else: "0"
getRemainingSupply(tokenDto.chainId, tokenDto.address) else:
getRemainingSupply(tokenDto.chainId, tokenDto.address)
burnState = getCommunityTokenBurnState(tokenDto.chainId, tokenDto.address) burnState = getCommunityTokenBurnState(tokenDto.chainId, tokenDto.address)
remoteDestructedAddresses = getRemoteDestructedAddresses(tokenDto.chainId, tokenDto.address) remoteDestructedAddresses = getRemoteDestructedAddresses(tokenDto.chainId, tokenDto.address)
destructedAmount = getRemoteDestructedAmount(communityTokens, tokenDto.chainId, tokenDto.address) destructedAmount = getRemoteDestructedAmount(communityTokens, tokenDto.chainId, tokenDto.address)
except Exception as e:
error "Remote token state retrieval error", message = getCurrentExceptionMsg()
return %* { return %* {
"address": tokenDto.address, "address": tokenDto.address,