aboutsummaryrefslogtreecommitdiff
path: root/lib/identity/definitions/sid.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/identity/definitions/sid.cpp')
-rw-r--r--lib/identity/definitions/sid.cpp14
1 files changed, 5 insertions, 9 deletions
diff --git a/lib/identity/definitions/sid.cpp b/lib/identity/definitions/sid.cpp
index 443dbedf..1ba4b3b5 100644
--- a/lib/identity/definitions/sid.cpp
+++ b/lib/identity/definitions/sid.cpp
@@ -6,19 +6,15 @@
using namespace QMatrixClient;
-QJsonObject QMatrixClient::toJson(const Sid& pod)
+void JsonObjectConverter<Sid>::dumpTo(
+ QJsonObject& jo, const Sid& pod)
{
- QJsonObject jo;
addParam<>(jo, QStringLiteral("sid"), pod.sid);
- return jo;
}
-Sid FromJsonObject<Sid>::operator()(const QJsonObject& jo) const
+void JsonObjectConverter<Sid>::fillFrom(
+ const QJsonObject& jo, Sid& result)
{
- Sid result;
- result.sid =
- fromJson<QString>(jo.value("sid"_ls));
-
- return result;
+ fromJson(jo.value("sid"_ls), result.sid);
}