From 7a0c37681bcf287dbb16e263c7b8f23124168c51 Mon Sep 17 00:00:00 2001 From: Ruthenic Date: Fri, 23 Feb 2024 13:17:21 -0500 Subject: [PATCH] wip reproxy + fix autoproxy for real this time --- src/commands/mod.rs | 1 + src/commands/reproxy.rs | 0 src/events/on_message.rs | 6 +++--- 3 files changed, 4 insertions(+), 3 deletions(-) create mode 100644 src/commands/reproxy.rs diff --git a/src/commands/mod.rs b/src/commands/mod.rs index b201108..a6c0fdd 100644 --- a/src/commands/mod.rs +++ b/src/commands/mod.rs @@ -7,6 +7,7 @@ pub mod import; pub mod info; pub mod mate; pub mod misc; +pub mod reproxy; pub mod settings; pub mod switch_logs; diff --git a/src/commands/reproxy.rs b/src/commands/reproxy.rs new file mode 100644 index 0000000..e69de29 diff --git a/src/events/on_message.rs b/src/events/on_message.rs index 7e7066e..492e6d8 100644 --- a/src/events/on_message.rs +++ b/src/events/on_message.rs @@ -40,14 +40,14 @@ pub async fn run(ctx: &SerenityContext, data: &Data, message: &Message) -> Resul let mut mate = get_matching_mate(&mates, &message.content); - if message.content.starts_with("\\") { - return Ok(()); - } if message.content.starts_with("\\\\") { update_latch(&settings_collection, message, None).await?; return Ok(()); } + if message.content.starts_with("\\") { + return Ok(()); + } if mate.is_none() { mate = get_autoproxied_mate(