feat: Show error properly to the user on yt command

This commit is contained in:
GiovaniFZ 2024-12-14 15:30:26 -03:00
parent 86e6664795
commit 7c8dba27f9
No known key found for this signature in database
GPG key ID: 63DD92181B575322
3 changed files with 4 additions and 2 deletions

View file

@ -139,7 +139,7 @@ module.exports = (bot) => {
fs.unlinkSync(mp4File);
} catch (error) {
await ctx.reply(`\`${error.message}\``, {
await ctx.reply(Strings.error, {
parse_mode: 'Markdown',
reply_to_message_id: ctx.message.message_id,
});
@ -165,7 +165,7 @@ module.exports = (bot) => {
}
} catch (error) {
console.error(error);
await ctx.reply(`\`${error.message}\``, {
await ctx.reply(Strings.error, {
parse_mode: 'Markdown',
reply_to_message_id: ctx.message.message_id,
});