use bot token from config

This commit is contained in:
Akulij 2025-03-30 18:17:03 +08:00
parent 668e6c53e6
commit d53c00a943

View File

@ -12,7 +12,7 @@ async fn main() -> Result<(), Box<dyn std::error::Error>>{
dotenvy::dotenv()?;
let config = Config::init_from_env()?;
let bot = Bot::from_env();
let bot = Bot::new(config.bot_token);
teloxide::repl(bot, |bot: Bot, msg: Message| async move {
bot.send_dice(msg.chat.id).await?;