From 4e360cf86a74051e2d4f98758c65ae29b97b7b8b Mon Sep 17 00:00:00 2001 From: Maiddog Date: Sun, 27 Aug 2017 17:54:16 -0500 Subject: Fix examples (#151) --- examples/07_sample_bot_structure/src/commands/math.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'examples/07_sample_bot_structure/src') diff --git a/examples/07_sample_bot_structure/src/commands/math.rs b/examples/07_sample_bot_structure/src/commands/math.rs index 2b1c1d2..3aaccc4 100644 --- a/examples/07_sample_bot_structure/src/commands/math.rs +++ b/examples/07_sample_bot_structure/src/commands/math.rs @@ -1,4 +1,7 @@ -command!(multiply(_ctx, msg, _args, one: f64, two: f64) { +command!(multiply(_ctx, msg, args) { + let one = args.single::().unwrap(); + let two = args.single::().unwrap(); + let product = one * two; let _ = msg.channel_id.say(product); -- cgit v1.2.3