aboutsummaryrefslogtreecommitdiff
path: root/lib/jobs/generated/users.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/jobs/generated/users.cpp')
-rw-r--r--lib/jobs/generated/users.cpp19
1 files changed, 10 insertions, 9 deletions
diff --git a/lib/jobs/generated/users.cpp b/lib/jobs/generated/users.cpp
index 33da4b43..b222cac5 100644
--- a/lib/jobs/generated/users.cpp
+++ b/lib/jobs/generated/users.cpp
@@ -10,17 +10,18 @@ using namespace QMatrixClient;
static const auto basePath = QStringLiteral("/_matrix/client/r0");
-SearchUserDirectoryJob::User::operator QJsonObject() const
-{
- QJsonObject o;
- o.insert("user_id", toJson(userId));
- o.insert("display_name", toJson(displayName));
- o.insert("avatar_url", toJson(avatarUrl));
-
- return o;
-}
namespace QMatrixClient
{
+ QJsonObject toJson(const SearchUserDirectoryJob::User& pod)
+ {
+ QJsonObject o;
+ o.insert("user_id", toJson(pod.userId));
+ o.insert("display_name", toJson(pod.displayName));
+ o.insert("avatar_url", toJson(pod.avatarUrl));
+
+ return o;
+ }
+
template <> struct FromJson<SearchUserDirectoryJob::User>
{
SearchUserDirectoryJob::User operator()(QJsonValue jv)