diff --git a/src/riotTags/rooms/room-type-picker.tag b/src/riotTags/rooms/room-type-picker.tag index ad301e1ae..f32340e44 100644 --- a/src/riotTags/rooms/room-type-picker.tag +++ b/src/riotTags/rooms/room-type-picker.tag @@ -39,10 +39,6 @@ room-type-picker.room-editor-TypeSwatches.tabbed.tall this.getTypeTextureRevision = type => glob.texturemap[type.texture].g.lastmod; - window.signals.on('typesChanged', typesChanged); - this.on('unmount', () => { - window.signals.off('typesChanged', typesChanged); - }); const fuseOptions = { shouldSort: true, tokenize: true, @@ -83,6 +79,11 @@ room-type-picker.room-editor-TypeSwatches.tabbed.tall this.update(); }; + window.signals.on('typesChanged', typesChanged); + this.on('unmount', () => { + window.signals.off('typesChanged', typesChanged); + }); + this.on('mount', () => { this.mounted = true; }); \ No newline at end of file