From b52eb9f108fb7af182e0cf29259cd4d522ed7f89 Mon Sep 17 00:00:00 2001 From: Nikita Pekin Date: Fri, 5 Jan 2018 19:43:34 -0500 Subject: Fix docs for User::has_role Update the docs for `User::has_role` to reflect that `Into` is only implemented for `PartialGuild`, `GuildId`, and `u64`, not `Guild`. (cherry picked from commit 00deef894ec458ac8abff914ed864ea63c47eda6) --- src/model/user.rs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/model') diff --git a/src/model/user.rs b/src/model/user.rs index 4a10566..227fadf 100644 --- a/src/model/user.rs +++ b/src/model/user.rs @@ -561,19 +561,20 @@ impl User { /// given [`Role`]. /// /// Three forms of data may be passed in to the guild parameter: either a - /// [`Guild`] itself, a [`GuildId`], or a `u64`. + /// [`PartialGuild`], a [`GuildId`], or a `u64`. /// /// # Examples /// /// Check if a guild has a [`Role`] by Id: /// /// ```rust,ignore - /// // Assumes a 'guild' and `role_id` have already been bound - /// let _ = message.author.has_role(guild, role_id); + /// // Assumes a 'guild_id' and `role_id` have already been bound + /// let _ = message.author.has_role(guild_id, role_id); /// ``` /// /// [`Guild`]: struct.Guild.html /// [`GuildId`]: struct.GuildId.html + /// [`PartialGuild`]: struct.PartialGuild.html /// [`Role`]: struct.Role.html /// [`Cache`]: ../cache/struct.Cache.html // no-cache would warn on guild_id. -- cgit v1.2.3