Skip to content

Commit

Permalink
makeRedacted: fix code formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
KitsuneRal committed Nov 10, 2019
1 parent cb869d4 commit 9d50c47
Showing 1 changed file with 10 additions and 16 deletions.
26 changes: 10 additions & 16 deletions lib/room.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1934,22 +1934,16 @@ RoomEventPtr makeRedacted(const RoomEvent& target,
const RedactionEvent& redaction)
{
auto originalJson = target.originalJsonObject();
static const QStringList keepKeys { EventIdKey,
TypeKey,
QStringLiteral("room_id"),
QStringLiteral("sender"),
StateKeyKey,
QStringLiteral("prev_content"),
ContentKey,
QStringLiteral("hashes"),
QStringLiteral("signatures"),
QStringLiteral("depth"),
QStringLiteral("prev_events"),
QStringLiteral("prev_state"),
QStringLiteral("auth_events"),
QStringLiteral("origin"),
QStringLiteral("origin_server_ts"),
QStringLiteral("membership") };
// clang-format off
static const QStringList keepKeys { EventIdKey, TypeKey,
QStringLiteral("room_id"), QStringLiteral("sender"), StateKeyKey,
QStringLiteral("prev_content"), ContentKey,
QStringLiteral("hashes"), QStringLiteral("signatures"),
QStringLiteral("depth"), QStringLiteral("prev_events"),
QStringLiteral("prev_state"), QStringLiteral("auth_events"),
QStringLiteral("origin"), QStringLiteral("origin_server_ts"),
QStringLiteral("membership") };
// clang-format on

std::vector<std::pair<Event::Type, QStringList>> keepContentKeysMap {
{ RoomMemberEvent::typeId(), { QStringLiteral("membership") } },
Expand Down

0 comments on commit 9d50c47

Please sign in to comment.