aboutsummaryrefslogtreecommitdiff
path: root/src/commands/meme/create.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/commands/meme/create.rs')
-rw-r--r--src/commands/meme/create.rs18
1 files changed, 15 insertions, 3 deletions
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::<String>()?;
@@ -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::<String>()?;