diff options
| author | Zeyla Hellyer <[email protected]> | 2017-02-15 09:27:39 -0800 |
|---|---|---|
| committer | Zeyla Hellyer <[email protected]> | 2017-02-15 09:27:39 -0800 |
| commit | 1787e00eab126680932076e24ac820cad0bfc383 (patch) | |
| tree | 54aab4f5dc5a1f211a76af4272d1b983cc049a84 /src/utils/builder/edit_role.rs | |
| parent | Update README for `methods` feature removal (diff) | |
| download | serenity-1787e00eab126680932076e24ac820cad0bfc383.tar.xz serenity-1787e00eab126680932076e24ac820cad0bfc383.zip | |
Update doctests for Context changes
Due to the Context having many methods removed, the doctests were
failing.
Update the doctests to use alternative methods to accomplish the same.
Example:
Before:
```rust
context.say("hi");
```
After:
```rust
message.channel_id.say("hi")
```
Diffstat (limited to 'src/utils/builder/edit_role.rs')
| -rw-r--r-- | src/utils/builder/edit_role.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/utils/builder/edit_role.rs b/src/utils/builder/edit_role.rs index 3410417..e9b86e9 100644 --- a/src/utils/builder/edit_role.rs +++ b/src/utils/builder/edit_role.rs @@ -19,8 +19,8 @@ use ::model::{Permissions, Role, permissions}; /// Create a hoisted, mentionable role named "a test role": /// /// ```rust,ignore -/// // assuming you are in a `context` and a `guild_id` has been bound -/// let role = context.create_role(guild_id, |r| r +/// // assuming a `channel_id` and `guild_id` has been bound +/// let role = channel_id.create_role(guild_id, |r| r /// .hoist(true) /// .mentionable(true) /// .name("a test role")); |