diff options
Diffstat (limited to 'db.go')
-rw-r--r-- | db.go | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -255,7 +255,11 @@ func dbGetMxPmRoom(protocol string, them connector.UserID, themMxId string, usMx } func dbDeletePmRoom(room *DbPmRoomMap) { - db.Delete(room) + if room.ID != 0 { + db.Delete(room) + } else { + log.Warnf("In dbDeletePmRoom: %#v (not deleting since primary key is zero)", room) + } } func dbGetMxUser(protocol string, userId connector.UserID) (string, error) { |