aboutsummaryrefslogtreecommitdiff
path: root/matrix/rooms
diff options
context:
space:
mode:
authorTulir Asokan <tulir@maunium.net>2019-06-16 14:29:03 +0300
committerTulir Asokan <tulir@maunium.net>2019-06-16 14:54:12 +0300
commit2b7d5d54011ffcc93511bf05f44163a4b7a1270c (patch)
tree48a88e26a12f04b3f922c9ec54c4e2db061125fb /matrix/rooms
parent6bb932212cbadac6eed59ac153ebe041523f7570 (diff)
Fix reply rendering infinite loop bug
Diffstat (limited to 'matrix/rooms')
-rw-r--r--matrix/rooms/room.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/matrix/rooms/room.go b/matrix/rooms/room.go
index a0918b1..be91065 100644
--- a/matrix/rooms/room.go
+++ b/matrix/rooms/room.go
@@ -148,6 +148,9 @@ func (room *Room) Load() {
room.lock.Lock()
room.load()
room.lock.Unlock()
+ if room.postLoad != nil {
+ room.postLoad()
+ }
}
func (room *Room) load() {
@@ -177,9 +180,6 @@ func (room *Room) load() {
debug.Print("Failed to decode room state:", err)
}
room.changed = false
- if room.postLoad != nil {
- room.postLoad()
- }
}
func (room *Room) Touch() {