From 630dfa94995f83b0b1ef1b1d0ea92b6569b0b72c Mon Sep 17 00:00:00 2001 From: Bruno Windels Date: Tue, 31 Jul 2018 15:33:56 +0200 Subject: [PATCH] make sure room.tags is always a valid object so no crashes happen later on --- src/models/room.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/models/room.js b/src/models/room.js index b426c7490..4f7ac3911 100644 --- a/src/models/room.js +++ b/src/models/room.js @@ -1143,7 +1143,7 @@ Room.prototype.addTags = function(event) { // } // XXX: do we need to deep copy here? - this.tags = event.getContent().tags; + this.tags = event.getContent().tags || {}; // XXX: we could do a deep-comparison to see if the tags have really // changed - but do we want to bother?