From b88d046846f63c9e30cdbee559d89f4ded00d0e6 Mon Sep 17 00:00:00 2001 From: jellywx Date: Mon, 15 Nov 2021 07:55:37 +0000 Subject: [PATCH] block mentions in todo command --- src/commands/todo_cmds.rs | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/src/commands/todo_cmds.rs b/src/commands/todo_cmds.rs index 951b84e..851d16b 100644 --- a/src/commands/todo_cmds.rs +++ b/src/commands/todo_cmds.rs @@ -274,7 +274,12 @@ DELETE FROM todos WHERE user_id = (SELECT id FROM users WHERE user = ?) AND guil self.add(extra, pool).await.unwrap(); - let _ = msg.channel_id.say(&ctx, content).await; + let _ = msg + .channel_id + .send_message(&ctx, |m| { + m.content(content).allowed_mentions(|m| m.empty_parse()) + }) + .await; } SubCommand::Remove => { @@ -286,7 +291,12 @@ DELETE FROM todos WHERE user_id = (SELECT id FROM users WHERE user = ?) AND guil 1, ); - let _ = msg.channel_id.say(&ctx, content).await; + let _ = msg + .channel_id + .send_message(&ctx, |m| { + m.content(content).allowed_mentions(|m| m.empty_parse()) + }) + .await; } else { let _ = msg .channel_id