fix(community): community tokens disappear when minting of a new token is finished
fixes #15076
This commit is contained in:
parent
ad7053f809
commit
174114538e
|
@ -333,6 +333,12 @@ proc createCommunitySectionItem[T](self: Module[T], communityDetails: CommunityD
|
||||||
# We will update the model later when we finish loading the accounts
|
# We will update the model later when we finish loading the accounts
|
||||||
self.controller.asyncGetRevealedAccountsForAllMembers(communityDetails.id)
|
self.controller.asyncGetRevealedAccountsForAllMembers(communityDetails.id)
|
||||||
|
|
||||||
|
# If there are tokens already in the model, we should keep the existing community tokens, until
|
||||||
|
# getCommunityTokensDetailsAsync will trigger onCommunityTokensDetailsLoaded
|
||||||
|
let existingCommunity = self.view.model().getItemById(communityDetails.id)
|
||||||
|
if not existingCommunity.isEmpty() and not existingCommunity.communityTokens.isNil:
|
||||||
|
communityTokensItems = existingCommunity.communityTokens.items
|
||||||
|
|
||||||
let (unviewedCount, notificationsCount) = self.controller.sectionUnreadMessagesAndMentionsCount(
|
let (unviewedCount, notificationsCount) = self.controller.sectionUnreadMessagesAndMentionsCount(
|
||||||
communityDetails.id,
|
communityDetails.id,
|
||||||
communityDetails.muted,
|
communityDetails.muted,
|
||||||
|
|
Loading…
Reference in New Issue