aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLymia Aluysia <[email protected]>2018-08-08 20:06:21 -0500
committerzeyla <[email protected]>2018-08-08 18:06:21 -0700
commit826220f351a688b2a6f1c6ec527e65a996861d22 (patch)
treefa249595b55987bfd78fa7e0d68a1b38d45cbd5f /src
parentBump to v0.5.7 (diff)
downloadserenity-826220f351a688b2a6f1c6ec527e65a996861d22.tar.xz
serenity-826220f351a688b2a6f1c6ec527e65a996861d22.zip
[routing] Fix various incorrect routes. (#364)
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 e416dcb..81d25a3 100644
--- a/src/http/routing.rs
+++ b/src/http/routing.rs
@@ -916,12 +916,12 @@ impl<'a> RouteInfo<'a> {
pub fn deconstruct(&self) -> (LightMethod, Route, Cow<str>) {
match *self {
RouteInfo::AddGroupRecipient { group_id, user_id } => (
- LightMethod::Post,
+ LightMethod::Put,
Route::None,
Cow::from(Route::group_recipient(group_id, user_id)),
),
RouteInfo::AddMemberRole { guild_id, role_id, user_id } => (
- LightMethod::Post,
+ LightMethod::Put,
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::Post,
+ LightMethod::Put,
Route::GuildsIdBansUserId(guild_id),
Cow::from(Route::guild_ban_optioned(
guild_id,
@@ -977,7 +977,7 @@ impl<'a> RouteInfo<'a> {
Cow::from(Route::channel_messages(channel_id, None)),
),
RouteInfo::CreatePermission { channel_id, target_id } => (
- LightMethod::Post,
+ LightMethod::Put,
Route::ChannelsIdPermissionsOverwriteId(channel_id),
Cow::from(Route::channel_permission(channel_id, target_id)),
),