aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorZeyla Hellyer <[email protected]>2018-08-08 15:55:39 -0700
committerZeyla Hellyer <[email protected]>2018-08-08 15:57:05 -0700
commit04b410ee75b2eb29f32e66fc137d3992a4972f1d (patch)
tree38384c102e7578030e4460761a0000385ff819c5 /src
parentFix erroneous deadlock detected messages. (#363) (diff)
downloadserenity-04b410ee75b2eb29f32e66fc137d3992a4972f1d.tar.xz
serenity-04b410ee75b2eb29f32e66fc137d3992a4972f1d.zip
[http] Fix some routing issues
Fix the following issues with the routing: - AddMemberRole now POSTs instead of DELETEs - GuildBanUser now POSTs instead of DELETEs - CreateRole now POSTs instead of DELETEs - CreateWebhook now POSTs instead of DELETEs These issues arose from commit hash bbbf63868a8ef3c0f21c1896f7afb96f4d8fbcc1.
Diffstat (limited to 'src')
-rw-r--r--src/http/routing.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/http/routing.rs b/src/http/routing.rs
index dfbbb7f..e416dcb 100644
--- a/src/http/routing.rs
+++ b/src/http/routing.rs
@@ -921,7 +921,7 @@ impl<'a> RouteInfo<'a> {
Cow::from(Route::group_recipient(group_id, user_id)),
),
RouteInfo::AddMemberRole { guild_id, role_id, user_id } => (
- LightMethod::Delete,
+ LightMethod::Post,
Route::GuildsIdMembersIdRolesId(guild_id),
Cow::from(Route::guild_member_role(guild_id, user_id, role_id)),
),
@@ -932,7 +932,7 @@ impl<'a> RouteInfo<'a> {
user_id,
} => (
// TODO
- LightMethod::Delete,
+ LightMethod::Post,
Route::GuildsIdBansUserId(guild_id),
Cow::from(Route::guild_ban_optioned(
guild_id,
@@ -997,12 +997,12 @@ impl<'a> RouteInfo<'a> {
)),
),
RouteInfo::CreateRole { guild_id } => (
- LightMethod::Delete,
+ LightMethod::Post,
Route::GuildsIdRoles(guild_id),
Cow::from(Route::guild_roles(guild_id)),
),
RouteInfo::CreateWebhook { channel_id } => (
- LightMethod::Delete,
+ LightMethod::Post,
Route::ChannelsIdWebhooks(channel_id),
Cow::from(Route::channel_webhooks(channel_id)),
),