Added LocaleString type that can be converted to String to reduce the ammount of as_refs

This commit is contained in:
2024-04-22 15:17:51 +03:00
parent 86c7b4d0c4
commit 305b796d51
35 changed files with 202 additions and 192 deletions

View File

@@ -12,13 +12,13 @@ pub async fn menu(
let markup = menu_markup("get", user_id, &db).await?;
if markup.inline_keyboard.is_empty() {
bot.send_message(msg.chat.id, locale.no_accounts_found.as_ref())
bot.send_message(msg.chat.id, &locale.no_accounts_found)
.reply_markup(deletion_markup(locale))
.await?;
return Ok(());
}
bot.send_message(msg.chat.id, locale.choose_account.as_ref())
bot.send_message(msg.chat.id, &locale.choose_account)
.reply_markup(markup)
.await?;
Ok(())