Skip to content

Commit

Permalink
docs(http): document mutable guild features
Browse files Browse the repository at this point in the history
Discord only allows the `COMMUNITY`, `DISCOVERABLE` and `INVITES_DISABLED` features to be edited manually.

Reference: discord/discord-api-docs#5270
  • Loading branch information
itohatweb committed Sep 16, 2022
1 parent 37c0e04 commit a1124a2
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions twilight-http/src/request/guild/update_guild.rs
Original file line number Diff line number Diff line change
Expand Up @@ -164,8 +164,16 @@ impl<'a> UpdateGuild<'a> {
///
/// Attempting to add or remove the `COMMUNITY` feature requires the
/// [`Permissions::ADMINISTRATOR`] permission.
///
/// Attempting to add or remove the `INVITES_DISABLED` feature requires
/// the [`Permissions::MANAGE_GUILD`] permission.
///
/// Attempting to add or remove the `DISCOVERABLE` feature requires
/// the [`Permissions::ADMINISTRATOR`] permission. Additionally the guild
/// must pass all the discovery requirements.
///
/// [`Permissions::ADMINISTRATOR`]: twilight_model::guild::Permissions::ADMINISTRATOR
/// [`Permissions::MANAGE_GUILD`]: twilight_model::guild::Permissions::MANAGE_GUILD
pub const fn features(mut self, features: &'a [&'a str]) -> Self {
self.fields.features = Some(features);

Expand Down

0 comments on commit a1124a2

Please sign in to comment.