aboutsummaryrefslogtreecommitdiff
path: root/lib/room.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/room.cpp')
-rw-r--r--lib/room.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/room.cpp b/lib/room.cpp
index 68095412..284eacd1 100644
--- a/lib/room.cpp
+++ b/lib/room.cpp
@@ -2835,8 +2835,11 @@ Room::Changes Room::processStateEvent(const RoomEvent& e)
}
, true); // By default, go forward with the state change
// clang-format on
- if (!proceed)
+ if (!proceed) {
+ if (!curStateEvent) // Remove the empty placeholder if one was created
+ d->currentState.remove({ e.matrixType(), e.stateKey() });
return Change::None;
+ }
// Change the state
const auto* const oldStateEvent =