From 92a4267efc76b01d9161c204596c74e0d128cd28 Mon Sep 17 00:00:00 2001 From: Kitsune Ral Date: Thu, 12 Nov 2020 18:52:06 +0100 Subject: Room: add power level events to redaction rules --- lib/room.cpp | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) (limited to 'lib/room.cpp') diff --git a/lib/room.cpp b/lib/room.cpp index 57de4f0c..09e3dea2 100644 --- a/lib/room.cpp +++ b/lib/room.cpp @@ -2075,16 +2075,14 @@ RoomEventPtr makeRedacted(const RoomEvent& target, std::vector> keepContentKeysMap { { RoomMemberEvent::typeId(), { QStringLiteral("membership") } }, - { RoomCreateEvent::typeId(), { QStringLiteral("creator") } } - // , { RoomJoinRules::typeId(), { QStringLiteral("join_rule") } } - // , { RoomPowerLevels::typeId(), - // { QStringLiteral("ban"), QStringLiteral("events"), - // QStringLiteral("events_default"), - // QStringLiteral("kick"), QStringLiteral("redact"), - // QStringLiteral("state_default"), QStringLiteral("users"), - // QStringLiteral("users_default") } } - , + { RoomCreateEvent::typeId(), { QStringLiteral("creator") } }, + { RoomPowerLevelsEvent::typeId(), + { QStringLiteral("ban"), QStringLiteral("events"), + QStringLiteral("events_default"), QStringLiteral("kick"), + QStringLiteral("redact"), QStringLiteral("state_default"), + QStringLiteral("users"), QStringLiteral("users_default") } }, { RoomAliasesEvent::typeId(), { QStringLiteral("aliases") } } + // , { RoomJoinRules::typeId(), { QStringLiteral("join_rule") } } // , { RoomHistoryVisibility::typeId(), // { QStringLiteral("history_visibility") } } }; -- cgit v1.2.3