aboutsummaryrefslogtreecommitdiff
path: root/lib/csapi/report_content.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/csapi/report_content.cpp')
-rw-r--r--lib/csapi/report_content.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/csapi/report_content.cpp b/lib/csapi/report_content.cpp
index 0a76d5b8..bc52208f 100644
--- a/lib/csapi/report_content.cpp
+++ b/lib/csapi/report_content.cpp
@@ -9,11 +9,11 @@ using namespace Quotient;
ReportContentJob::ReportContentJob(const QString& roomId, const QString& eventId,
Omittable<int> score, const QString& reason)
: BaseJob(HttpVerb::Post, QStringLiteral("ReportContentJob"),
- makePath("/_matrix/client/r0", "/rooms/", roomId, "/report/",
+ makePath("/_matrix/client/v3", "/rooms/", roomId, "/report/",
eventId))
{
- QJsonObject _data;
- addParam<IfNotEmpty>(_data, QStringLiteral("score"), score);
- addParam<IfNotEmpty>(_data, QStringLiteral("reason"), reason);
- setRequestData(std::move(_data));
+ QJsonObject _dataJson;
+ addParam<IfNotEmpty>(_dataJson, QStringLiteral("score"), score);
+ addParam<IfNotEmpty>(_dataJson, QStringLiteral("reason"), reason);
+ setRequestData({ _dataJson });
}