From 8b2ccf363ac6894c21e256844948c8327645f0db Mon Sep 17 00:00:00 2001 From: Nathan Perry Date: Sun, 17 Nov 2019 22:51:59 -0500 Subject: mostly fixed --- src/commands/meme/create.rs | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) (limited to 'src/commands/meme/create.rs') diff --git a/src/commands/meme/create.rs b/src/commands/meme/create.rs index 0851961..7f590b1 100644 --- a/src/commands/meme/create.rs +++ b/src/commands/meme/create.rs @@ -7,13 +7,25 @@ use std::{ }; use diesel::result::Error as DieselError; +use log::{ + debug, + error, + warn, +}; use serenity::{ - framework::standard::{Args, Delimiter}, + framework::standard::{ + Args, CommandResult, + Delimiter, + macros::command, + }, model::channel::Message, prelude::*, }; use url::Url; +use anyhow::anyhow; +use lazy_static::lazy_static; + use crate::{ audio::{ parse_times, @@ -34,7 +46,7 @@ lazy_static! { } #[command] -pub fn addmeme(ctx: &mut Context, msg: &Message, args: Args) -> Result<()> { +pub fn addmeme(ctx: &mut Context, msg: &Message, args: Args) -> CommandResult { let mut args = Args::new(args.rest(), delims.as_ref()); let title = args.single_quoted::()?; @@ -81,7 +93,7 @@ pub fn addmeme(ctx: &mut Context, msg: &Message, args: Args) -> Result<()> { } #[command] -pub fn addaudiomeme(ctx: &mut Context, msg: &Message, args: Args) -> Result<()> { +pub fn addaudiomeme(ctx: &mut Context, msg: &Message, args: Args) -> CommandResult { let mut args = Args::new(args.rest(), delims.as_ref()); let title = args.single_quoted::()?; -- cgit v1.3.1