aboutsummaryrefslogtreecommitdiff
path: root/lib/csapi/definitions/push_ruleset.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/csapi/definitions/push_ruleset.cpp')
-rw-r--r--lib/csapi/definitions/push_ruleset.cpp20
1 files changed, 10 insertions, 10 deletions
diff --git a/lib/csapi/definitions/push_ruleset.cpp b/lib/csapi/definitions/push_ruleset.cpp
index ca2bbc0d..c424f686 100644
--- a/lib/csapi/definitions/push_ruleset.cpp
+++ b/lib/csapi/definitions/push_ruleset.cpp
@@ -9,11 +9,11 @@ using namespace QMatrixClient;
QJsonObject QMatrixClient::toJson(const PushRuleset& pod)
{
QJsonObject _json;
- addParam<IfNotEmpty>(_json, "content", pod.content);
- addParam<IfNotEmpty>(_json, "override", pod.override);
- addParam<IfNotEmpty>(_json, "room", pod.room);
- addParam<IfNotEmpty>(_json, "sender", pod.sender);
- addParam<IfNotEmpty>(_json, "underride", pod.underride);
+ addParam<IfNotEmpty>(_json, QStringLiteral("content"), pod.content);
+ addParam<IfNotEmpty>(_json, QStringLiteral("override"), pod.override);
+ addParam<IfNotEmpty>(_json, QStringLiteral("room"), pod.room);
+ addParam<IfNotEmpty>(_json, QStringLiteral("sender"), pod.sender);
+ addParam<IfNotEmpty>(_json, QStringLiteral("underride"), pod.underride);
return _json;
}
@@ -22,15 +22,15 @@ PushRuleset FromJson<PushRuleset>::operator()(const QJsonValue& jv)
const auto& _json = jv.toObject();
PushRuleset result;
result.content =
- fromJson<QVector<PushRule>>(_json.value("content"));
+ fromJson<QVector<PushRule>>(_json.value("content"_ls));
result.override =
- fromJson<QVector<PushRule>>(_json.value("override"));
+ fromJson<QVector<PushRule>>(_json.value("override"_ls));
result.room =
- fromJson<QVector<PushRule>>(_json.value("room"));
+ fromJson<QVector<PushRule>>(_json.value("room"_ls));
result.sender =
- fromJson<QVector<PushRule>>(_json.value("sender"));
+ fromJson<QVector<PushRule>>(_json.value("sender"_ls));
result.underride =
- fromJson<QVector<PushRule>>(_json.value("underride"));
+ fromJson<QVector<PushRule>>(_json.value("underride"_ls));
return result;
}