Ready for new release

This commit is contained in:
Ladislav Hano 2024-02-16 22:06:12 +01:00
parent 1186cd3226
commit 4a7ac0c023

View file

@ -5,17 +5,22 @@ use serenity::http::Http;
pub async fn send_error(_http: Arc<Http>, msg: String) { pub async fn send_error(_http: Arc<Http>, msg: String) {
println!("ERROR: {msg}"); println!("ERROR: {msg}");
#[cfg(feature="RELEASE")] #[cfg(feature="RELEASE")] {
use serenity::all::ChannelId;
use serenity::all::CreateMessage;
use std::process::exit;
match ChannelId::new(1199495008416440491) match ChannelId::new(1199495008416440491)
.send_message(_http, CreateMessage::new().content(msg)).await { .send_message(_http, CreateMessage::new().content(msg)).await {
Ok(_) => { return; } Ok(_) => { return; }
Err(_) => { exit(-1) } Err(_) => { exit(-1) }
}; };
} }
}
#[cfg(feature="RELEASE")] #[cfg(feature="RELEASE")]
pub async fn hello(http: Arc<Http>) { pub async fn hello(http: Arc<Http>) {
use serenity::http::Http; use serenity::all::ChannelId;
let messages = [ let messages = [
"AAAAAAAAAAAAAAAAAAAA", "AAAAAAAAAAAAAAAAAAAA",