fix(CommunityRequest): fix request list emptying after accepting

Fixes #2474
This commit is contained in:
Jonathan Rainville 2021-05-26 15:25:29 -04:00
parent b213aa230d
commit c8cc65506b
3 changed files with 2 additions and 25 deletions

View File

@ -43,6 +43,7 @@ QtObject:
self.categories.setCategories(communityItem.categories)
self.members.setMembers(communityItem.members)
self.nbMembersChanged()
if communityItem.membershipRequests.len > 0:
self.communityMembershipRequestList.setNewData(communityItem.membershipRequests)
proc activeChanged*(self: CommunityItemView) {.signal.}

View File

@ -223,14 +223,6 @@ proc init*(self: ChatModel, pubKey: string) =
self.mailserverReady = true
self.requestMissingCommunityInfos()
if (topics.len == 0):
warn "No topics found for chats. Cannot load past messages"
else:
self.events.once("mailserverAvailable") do(a: Args):
self.mailserverReady = true
self.requestMissingCommunityInfos()
self.events.emit("mailserverTopics", TopicArgs(topics: topics));
self.events.on("contactUpdate") do(a: Args):
var evArgs = ContactUpdateArgs(a)
self.updateContacts(evArgs.contacts)

View File

@ -61,22 +61,6 @@ Item {
return Utils.removeStatusEns(alias)
}
property string displayUserName: {
if (isCurrentUser) {
//% "You"
return qsTrId("You")
}
if (localName !== "") {
return localName
}
if (userName !== "") {
return Utils.removeStatusEns(userName)
}
return Utils.removeStatusEns(alias)
}
property string authorCurrentMsg: "authorCurrentMsg"
property string authorPrevMsg: "authorPrevMsg"