handle leave chat from matrix side

This commit is contained in:
Karmanyaah Malhotra committed 2021-02-27 20:07:46 -05:00
1 parent b5af55122e
commit 3e75ffaf05
6 files changed
+279 -262

No files matched your search

+1 -1
View File
@@ -171,7 +171,7 @@ func (portal *Portal) Update() {
}
func (portal *Portal) Delete() {
ans := portal.db.Delete(&portal)
ans := portal.db.Where("jid = ? AND receiver = ?", portal.Key.JID, portal.Key.Receiver).Delete(&portal)
if ans.Error != nil {
portal.log.Warnfln("Failed to delete %s: %v", portal.Key, ans.Error)
}