aboutsummaryrefslogtreecommitdiff
path: root/lib/csapi/inviting.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/csapi/inviting.cpp')
-rw-r--r--lib/csapi/inviting.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/csapi/inviting.cpp b/lib/csapi/inviting.cpp
index bc1863ce..41a8b5be 100644
--- a/lib/csapi/inviting.cpp
+++ b/lib/csapi/inviting.cpp
@@ -11,8 +11,8 @@ InviteUserJob::InviteUserJob(const QString& roomId, const QString& userId,
: BaseJob(HttpVerb::Post, QStringLiteral("InviteUserJob"),
makePath("/_matrix/client/v3", "/rooms/", roomId, "/invite"))
{
- QJsonObject _data;
- addParam<>(_data, QStringLiteral("user_id"), userId);
- addParam<IfNotEmpty>(_data, QStringLiteral("reason"), reason);
- setRequestData(std::move(_data));
+ QJsonObject _dataJson;
+ addParam<>(_dataJson, QStringLiteral("user_id"), userId);
+ addParam<IfNotEmpty>(_dataJson, QStringLiteral("reason"), reason);
+ setRequestData({ _dataJson });
}