aboutsummaryrefslogtreecommitdiff
path: root/src/framework/create_command.rs
diff options
context:
space:
mode:
authoracdenisSK <[email protected]>2017-08-18 00:53:20 +0200
committeracdenisSK <[email protected]>2017-08-18 00:53:20 +0200
commit106a4d5f8ff22a829a9486ce88fa8326184828fa (patch)
tree650c539ce1fac58f07f568077a6c396b54cc9027 /src/framework/create_command.rs
parentFix args when `use_quotes` is true (diff)
downloadserenity-106a4d5f8ff22a829a9486ce88fa8326184828fa.tar.xz
serenity-106a4d5f8ff22a829a9486ce88fa8326184828fa.zip
Allow the user to be given the original message (as in, the message used to construct the `args`)
Diffstat (limited to 'src/framework/create_command.rs')
-rw-r--r--src/framework/create_command.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/framework/create_command.rs b/src/framework/create_command.rs
index cf78174..3bb019c 100644
--- a/src/framework/create_command.rs
+++ b/src/framework/create_command.rs
@@ -97,7 +97,7 @@ impl CreateCommand {
///
/// [`exec_str`]: #method.exec_str
pub fn exec<F>(mut self, func: F) -> Self
- where F: Fn(&mut Context, &Message, Vec<String>) -> Result<(), String>
+ where F: Fn(&mut Context, &Message, Vec<String>, String) -> Result<(), String>
+ Send
+ Sync
+ 'static {
@@ -217,7 +217,7 @@ impl Default for Command {
Command {
aliases: Vec::new(),
checks: Vec::default(),
- exec: CommandType::Basic(Box::new(|_, _, _| Ok(()))),
+ exec: CommandType::Basic(Box::new(|_, _, _, _| Ok(()))),
desc: None,
usage: None,
example: None,