2024-09-12 13:44:06 +03:00
|
|
|
use mxlink::MessageResponseType;
|
|
|
|
|
|
2025-02-27 07:46:16 +02:00
|
|
|
use crate::{Bot, entity::MessageContext, strings};
|
2024-09-12 13:44:06 +03:00
|
|
|
|
|
|
|
|
use super::ControllerType;
|
|
|
|
|
|
|
|
|
|
pub fn determine_controller(_text: &str) -> ControllerType {
|
|
|
|
|
ControllerType::UsageHelp
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
pub async fn handle_help(message_context: &MessageContext, bot: &Bot) -> anyhow::Result<()> {
|
|
|
|
|
bot.messaging()
|
|
|
|
|
.send_text_markdown_no_fail(
|
|
|
|
|
message_context.room(),
|
|
|
|
|
strings::usage::intro(bot.command_prefix()),
|
|
|
|
|
MessageResponseType::Reply(message_context.thread_info().root_event_id.clone()),
|
|
|
|
|
)
|
|
|
|
|
.await;
|
|
|
|
|
|
|
|
|
|
Ok(())
|
|
|
|
|
}
|