aboutsummaryrefslogtreecommitdiff
path: root/lib/events/roomevent.cpp
diff options
context:
space:
mode:
authorKitsune Ral <Kitsune-Ral@users.sf.net>2020-11-12 18:51:35 +0100
committerKitsune Ral <Kitsune-Ral@users.sf.net>2020-11-12 18:51:35 +0100
commit4cc8838c3bbe712493a4f6ddbecd0f7093e907bb (patch)
treea0efd33b273d044acf380b1f1370cf27d50c6c96 /lib/events/roomevent.cpp
parent39b80fa8eb9b70d287aa453663b845319d8b6196 (diff)
downloadlibquotient-4cc8838c3bbe712493a4f6ddbecd0f7093e907bb.tar.gz
libquotient-4cc8838c3bbe712493a4f6ddbecd0f7093e907bb.zip
More JSON key constants
Diffstat (limited to 'lib/events/roomevent.cpp')
-rw-r--r--lib/events/roomevent.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/events/roomevent.cpp b/lib/events/roomevent.cpp
index 0a4332ad..3d87ef18 100644
--- a/lib/events/roomevent.cpp
+++ b/lib/events/roomevent.cpp
@@ -51,12 +51,12 @@ QDateTime RoomEvent::originTimestamp() const
QString RoomEvent::roomId() const
{
- return fullJson()["room_id"_ls].toString();
+ return fullJson()[RoomIdKeyL].toString();
}
QString RoomEvent::senderId() const
{
- return fullJson()["sender"_ls].toString();
+ return fullJson()[SenderKeyL].toString();
}
bool RoomEvent::isReplaced() const
@@ -90,12 +90,12 @@ QString RoomEvent::stateKey() const
void RoomEvent::setRoomId(const QString& roomId)
{
- editJson().insert(QStringLiteral("room_id"), roomId);
+ editJson().insert(RoomIdKey, roomId);
}
void RoomEvent::setSender(const QString& senderId)
{
- editJson().insert(QStringLiteral("sender"), senderId);
+ editJson().insert(SenderKey, senderId);
}
void RoomEvent::setTransactionId(const QString& txnId)