aboutsummaryrefslogtreecommitdiff
path: root/lib/csapi/kicking.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/csapi/kicking.cpp')
-rw-r--r--lib/csapi/kicking.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/csapi/kicking.cpp b/lib/csapi/kicking.cpp
index 3bedcb34..4ca39c4c 100644
--- a/lib/csapi/kicking.cpp
+++ b/lib/csapi/kicking.cpp
@@ -11,8 +11,8 @@ KickJob::KickJob(const QString& roomId, const QString& userId,
: BaseJob(HttpVerb::Post, QStringLiteral("KickJob"),
makePath("/_matrix/client/v3", "/rooms/", roomId, "/kick"))
{
- 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 });
}