fix: fix leaving a channel with no messages
This commit is contained in:
parent
37edfed446
commit
a0c1b1552d
|
@ -423,8 +423,9 @@ QtObject:
|
||||||
|
|
||||||
proc removeChat*(self: ChatsView, chatId: string) =
|
proc removeChat*(self: ChatsView, chatId: string) =
|
||||||
discard self.chats.removeChatItemFromList(chatId)
|
discard self.chats.removeChatItemFromList(chatId)
|
||||||
self.messageList[chatId].delete
|
if (self.messageList.hasKey(chatId)):
|
||||||
self.messageList.del(chatId)
|
self.messageList[chatId].delete
|
||||||
|
self.messageList.del(chatId)
|
||||||
|
|
||||||
proc removeMessagesFromTimeline*(self: ChatsView, chatId: string) =
|
proc removeMessagesFromTimeline*(self: ChatsView, chatId: string) =
|
||||||
self.messageList[status_utils.getTimelineChatId()].deleteMessagesByChatId(chatId)
|
self.messageList[status_utils.getTimelineChatId()].deleteMessagesByChatId(chatId)
|
||||||
|
|
Loading…
Reference in New Issue