diff options
Diffstat (limited to 'jobs/generated/banning.cpp')
-rw-r--r-- | jobs/generated/banning.cpp | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/jobs/generated/banning.cpp b/jobs/generated/banning.cpp index b7888062..f66b27b6 100644 --- a/jobs/generated/banning.cpp +++ b/jobs/generated/banning.cpp @@ -14,29 +14,21 @@ static const auto basePath = QStringLiteral("/_matrix/client/r0"); BanJob::BanJob(const QString& roomId, const QString& userId, const QString& reason) : BaseJob(HttpVerb::Post, "BanJob", - basePath % "/rooms/" % roomId % "/ban", - Query { } - ) + basePath % "/rooms/" % roomId % "/ban") { QJsonObject _data; _data.insert("user_id", toJson(userId)); if (!reason.isEmpty()) _data.insert("reason", toJson(reason)); setRequestData(_data); - - addExpectedContentType("application/json"); } UnbanJob::UnbanJob(const QString& roomId, const QString& userId) : BaseJob(HttpVerb::Post, "UnbanJob", - basePath % "/rooms/" % roomId % "/unban", - Query { } - ) + basePath % "/rooms/" % roomId % "/unban") { QJsonObject _data; _data.insert("user_id", toJson(userId)); setRequestData(_data); - - addExpectedContentType("application/json"); } |