aboutsummaryrefslogtreecommitdiff
path: root/src/ext/framework/command.rs
diff options
context:
space:
mode:
authorZeyla Hellyer <[email protected]>2017-04-18 21:21:30 -0700
committerZeyla Hellyer <[email protected]>2017-04-19 14:53:32 -0700
commitff4437addb01e5c6c3ad8c5b1830db0d0a86396b (patch)
tree1aa48b22a111174172b97ee9b41998ac3656c73d /src/ext/framework/command.rs
parentRemove ChannelPinsAck/MessageAck events (diff)
downloadserenity-ff4437addb01e5c6c3ad8c5b1830db0d0a86396b.tar.xz
serenity-ff4437addb01e5c6c3ad8c5b1830db0d0a86396b.zip
Accept a slice of args in help commands
The help commands don't actually need to have the arguments passed by value, so passing them by reference is fine.
Diffstat (limited to 'src/ext/framework/command.rs')
-rw-r--r--src/ext/framework/command.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ext/framework/command.rs b/src/ext/framework/command.rs
index 70ee4ff..76ca416 100644
--- a/src/ext/framework/command.rs
+++ b/src/ext/framework/command.rs
@@ -7,7 +7,7 @@ use std::collections::HashMap;
pub type Check = Fn(&mut Context, &Message) -> bool + Send + Sync + 'static;
pub type Exec = Fn(&mut Context, &Message, Vec<String>) -> Result<(), String> + Send + Sync + 'static;
-pub type Help = Fn(&mut Context, &Message, HashMap<String, Arc<CommandGroup>>, Vec<String>) -> Result<(), String> + Send + Sync + 'static;
+pub type Help = Fn(&mut Context, &Message, HashMap<String, Arc<CommandGroup>>, &[String]) -> Result<(), String> + Send + Sync + 'static;
pub type BeforeHook = Fn(&mut Context, &Message, &String) -> bool + Send + Sync + 'static;
pub type AfterHook = Fn(&mut Context, &Message, &String, Result<(), String>) + Send + Sync + 'static;
#[doc(hidden)]