diff options
author | Kitsune Ral <Kitsune-Ral@users.sf.net> | 2018-01-05 11:01:18 +0900 |
---|---|---|
committer | Kitsune Ral <Kitsune-Ral@users.sf.net> | 2018-01-09 11:54:40 +0900 |
commit | 7169338dedbf0184da4c971e7cecb6be13b1d129 (patch) | |
tree | 6d6fcecf323cd8f39c24349abd139a2a28fa4c48 /jobs | |
parent | b142117d78a2a4ce21e818c62cb7a10cff80af0d (diff) | |
download | libquotient-7169338dedbf0184da4c971e7cecb6be13b1d129.tar.gz libquotient-7169338dedbf0184da4c971e7cecb6be13b1d129.zip |
jobs/generated: Use BaseJob::addExpectedContentType()
Diffstat (limited to 'jobs')
-rw-r--r-- | jobs/generated/administrative_contact.cpp | 2 | ||||
-rw-r--r-- | jobs/generated/banning.cpp | 4 | ||||
-rw-r--r-- | jobs/generated/directory.cpp | 2 | ||||
-rw-r--r-- | jobs/generated/inviting.cpp | 2 | ||||
-rw-r--r-- | jobs/generated/kicking.cpp | 2 | ||||
-rw-r--r-- | jobs/generated/list_public_rooms.cpp | 2 | ||||
-rw-r--r-- | jobs/generated/login.cpp | 2 | ||||
-rw-r--r-- | jobs/generated/profile.cpp | 4 | ||||
-rw-r--r-- | jobs/generated/receipts.cpp | 2 | ||||
-rw-r--r-- | jobs/generated/redaction.cpp | 2 | ||||
-rw-r--r-- | jobs/generated/third_party_membership.cpp | 2 | ||||
-rw-r--r-- | jobs/generated/typing.cpp | 2 |
12 files changed, 28 insertions, 0 deletions
diff --git a/jobs/generated/administrative_contact.cpp b/jobs/generated/administrative_contact.cpp index ca029f58..584c447f 100644 --- a/jobs/generated/administrative_contact.cpp +++ b/jobs/generated/administrative_contact.cpp @@ -102,6 +102,8 @@ Post3PIDsJob::Post3PIDsJob(const ThreePidCredentials& threePidCreds, bool bind) _data.insert("three_pid_creds", toJson(threePidCreds)); _data.insert("bind", toJson(bind)); setRequestData(_data); + + addExpectedContentType("application/json"); } RequestTokenTo3PIDJob::RequestTokenTo3PIDJob() diff --git a/jobs/generated/banning.cpp b/jobs/generated/banning.cpp index d7708cc6..b7888062 100644 --- a/jobs/generated/banning.cpp +++ b/jobs/generated/banning.cpp @@ -23,6 +23,8 @@ BanJob::BanJob(const QString& roomId, const QString& userId, const QString& reas if (!reason.isEmpty()) _data.insert("reason", toJson(reason)); setRequestData(_data); + + addExpectedContentType("application/json"); } UnbanJob::UnbanJob(const QString& roomId, const QString& userId) @@ -34,5 +36,7 @@ UnbanJob::UnbanJob(const QString& roomId, const QString& userId) QJsonObject _data; _data.insert("user_id", toJson(userId)); setRequestData(_data); + + addExpectedContentType("application/json"); } diff --git a/jobs/generated/directory.cpp b/jobs/generated/directory.cpp index 1fd1e443..ea6d493f 100644 --- a/jobs/generated/directory.cpp +++ b/jobs/generated/directory.cpp @@ -22,6 +22,8 @@ SetRoomAliasJob::SetRoomAliasJob(const QString& roomAlias, const QString& roomId if (!roomId.isEmpty()) _data.insert("room_id", toJson(roomId)); setRequestData(_data); + + addExpectedContentType("application/json"); } class GetRoomIdByAliasJob::Private diff --git a/jobs/generated/inviting.cpp b/jobs/generated/inviting.cpp index bdf257dd..6cd67ad7 100644 --- a/jobs/generated/inviting.cpp +++ b/jobs/generated/inviting.cpp @@ -21,5 +21,7 @@ InviteUserJob::InviteUserJob(const QString& roomId, const QString& userId) QJsonObject _data; _data.insert("user_id", toJson(userId)); setRequestData(_data); + + addExpectedContentType("application/json"); } diff --git a/jobs/generated/kicking.cpp b/jobs/generated/kicking.cpp index 3488b387..bf94fe59 100644 --- a/jobs/generated/kicking.cpp +++ b/jobs/generated/kicking.cpp @@ -23,5 +23,7 @@ KickJob::KickJob(const QString& roomId, const QString& userId, const QString& re if (!reason.isEmpty()) _data.insert("reason", toJson(reason)); setRequestData(_data); + + addExpectedContentType("application/json"); } diff --git a/jobs/generated/list_public_rooms.cpp b/jobs/generated/list_public_rooms.cpp index d15e9de3..1e775f1b 100644 --- a/jobs/generated/list_public_rooms.cpp +++ b/jobs/generated/list_public_rooms.cpp @@ -205,6 +205,8 @@ QueryPublicRoomsJob::QueryPublicRoomsJob(const QString& server, double limit, co _data.insert("since", toJson(since)); _data.insert("filter", toJson(filter)); setRequestData(_data); + + addExpectedContentType("application/json"); } QueryPublicRoomsJob::~QueryPublicRoomsJob() = default; diff --git a/jobs/generated/login.cpp b/jobs/generated/login.cpp index bbfff0da..67d991db 100644 --- a/jobs/generated/login.cpp +++ b/jobs/generated/login.cpp @@ -44,6 +44,8 @@ LoginJob::LoginJob(const QString& type, const QString& user, const QString& medi if (!initialDeviceDisplayName.isEmpty()) _data.insert("initial_device_display_name", toJson(initialDeviceDisplayName)); setRequestData(_data); + + addExpectedContentType("application/json"); } LoginJob::~LoginJob() = default; diff --git a/jobs/generated/profile.cpp b/jobs/generated/profile.cpp index 27bab0b8..b30b9a36 100644 --- a/jobs/generated/profile.cpp +++ b/jobs/generated/profile.cpp @@ -22,6 +22,8 @@ SetDisplayNameJob::SetDisplayNameJob(const QString& userId, const QString& displ if (!displayname.isEmpty()) _data.insert("displayname", toJson(displayname)); setRequestData(_data); + + addExpectedContentType("application/json"); } class GetDisplayNameJob::Private @@ -61,6 +63,8 @@ SetAvatarUrlJob::SetAvatarUrlJob(const QString& userId, const QString& avatarUrl if (!avatarUrl.isEmpty()) _data.insert("avatar_url", toJson(avatarUrl)); setRequestData(_data); + + addExpectedContentType("application/json"); } class GetAvatarUrlJob::Private diff --git a/jobs/generated/receipts.cpp b/jobs/generated/receipts.cpp index 1c8bd80f..20e58ffb 100644 --- a/jobs/generated/receipts.cpp +++ b/jobs/generated/receipts.cpp @@ -19,5 +19,7 @@ PostReceiptJob::PostReceiptJob(const QString& roomId, const QString& receiptType ) { setRequestData(Data(receipt)); + + addExpectedContentType("application/json"); } diff --git a/jobs/generated/redaction.cpp b/jobs/generated/redaction.cpp index 9207f344..218e1aa6 100644 --- a/jobs/generated/redaction.cpp +++ b/jobs/generated/redaction.cpp @@ -28,6 +28,8 @@ RedactEventJob::RedactEventJob(const QString& roomId, const QString& eventId, co if (!reason.isEmpty()) _data.insert("reason", toJson(reason)); setRequestData(_data); + + addExpectedContentType("application/json"); } RedactEventJob::~RedactEventJob() = default; diff --git a/jobs/generated/third_party_membership.cpp b/jobs/generated/third_party_membership.cpp index dbb3ebee..f5ccf123 100644 --- a/jobs/generated/third_party_membership.cpp +++ b/jobs/generated/third_party_membership.cpp @@ -23,5 +23,7 @@ InviteBy3PIDJob::InviteBy3PIDJob(const QString& roomId, const QString& idServer, _data.insert("medium", toJson(medium)); _data.insert("address", toJson(address)); setRequestData(_data); + + addExpectedContentType("application/json"); } diff --git a/jobs/generated/typing.cpp b/jobs/generated/typing.cpp index a6817cb9..05e5fd1e 100644 --- a/jobs/generated/typing.cpp +++ b/jobs/generated/typing.cpp @@ -22,5 +22,7 @@ SetTypingJob::SetTypingJob(const QString& userId, const QString& roomId, bool ty _data.insert("typing", toJson(typing)); _data.insert("timeout", toJson(timeout)); setRequestData(_data); + + addExpectedContentType("application/json"); } |