diff options
| author | acdenisSK <[email protected]> | 2017-08-24 15:26:49 +0200 |
|---|---|---|
| committer | acdenisSK <[email protected]> | 2017-08-24 16:36:01 +0200 |
| commit | b3a5bc89ad1c09290fb1c15ca3b36fe17c3796f3 (patch) | |
| tree | 315e16f7b252d22b5f832302e722a85c9e6a9b6e /src/framework/standard/create_group.rs | |
| parent | Allow FromStr for User to use REST (#147) (diff) | |
| download | serenity-b3a5bc89ad1c09290fb1c15ca3b36fe17c3796f3.tar.xz serenity-b3a5bc89ad1c09290fb1c15ca3b36fe17c3796f3.zip | |
Revamp `RwLock` usage in the lib
Also not quite sure if they goofed rustfmt or something, but its changes it did were a bit bizarre.
Diffstat (limited to 'src/framework/standard/create_group.rs')
| -rw-r--r-- | src/framework/standard/create_group.rs | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/src/framework/standard/create_group.rs b/src/framework/standard/create_group.rs index 013ba67..d533c6a 100644 --- a/src/framework/standard/create_group.rs +++ b/src/framework/standard/create_group.rs @@ -35,9 +35,7 @@ impl CreateGroup { if let Some(ref prefix) = self.0.prefix { self.0.commands.insert( format!("{} {}", prefix, n.to_owned()), - CommandOrAlias::Alias( - format!("{} {}", prefix, command_name.to_string()), - ), + CommandOrAlias::Alias(format!("{} {}", prefix, command_name.to_string())), ); } else { self.0.commands.insert( @@ -61,10 +59,9 @@ impl CreateGroup { where F: Fn(&mut Context, &Message, Args) -> Result<(), String> + Send + Sync + 'static { let cmd = Arc::new(Command::new(f)); - self.0.commands.insert( - command_name.to_owned(), - CommandOrAlias::Command(cmd), - ); + self.0 + .commands + .insert(command_name.to_owned(), CommandOrAlias::Command(cmd)); self } |