Handle conversation deleted event

This commit is contained in:
2021-03-13 13:39:03 +01:00
parent 0a5a2637f5
commit 54d8245f91
3 changed files with 21 additions and 1 deletions

View File

@ -1505,4 +1505,13 @@ document.addEventListener("removedUserFromConv", e => {
return;
ConvChatWindow.__conversationsCache["conversation-"+msg.conv_id].box.closeFunction();
});
document.addEventListener("deletedConversation", e => {
const convID = e.detail;
if(!ConvService.__serviceCache.hasOwnProperty("conversation-" + convID))
return;
ConvChatWindow.__conversationsCache["conversation-"+convID].box.closeFunction();
});