1
Fork 0
mirror of https://github.com/wlinator/luminara.git synced 2024-10-02 18:23:12 +00:00

Properly handle is_nsfw() errors

This commit is contained in:
wlinator 2024-09-22 17:37:41 +02:00
parent 4267a8f50d
commit e43bbf91c5
2 changed files with 2 additions and 0 deletions

View file

@ -17,6 +17,7 @@ error_map: dict[type[Exception], str] = {
commands.NoPrivateMessage: CONST.STRINGS["error_no_private_message_description"], commands.NoPrivateMessage: CONST.STRINGS["error_no_private_message_description"],
commands.NotOwner: CONST.STRINGS["error_not_owner_unknown"], commands.NotOwner: CONST.STRINGS["error_not_owner_unknown"],
commands.PrivateMessageOnly: CONST.STRINGS["error_private_message_only_description"], commands.PrivateMessageOnly: CONST.STRINGS["error_private_message_only_description"],
commands.NSFWChannelRequired: CONST.STRINGS["error_nsfw_channel_required_description"],
exceptions.BirthdaysDisabled: CONST.STRINGS["error_birthdays_disabled_description"], exceptions.BirthdaysDisabled: CONST.STRINGS["error_birthdays_disabled_description"],
} }

View file

@ -178,6 +178,7 @@
"error_not_enough_cash": "you don't have enough cash.", "error_not_enough_cash": "you don't have enough cash.",
"error_not_owner": "{0} tried to use a bot admin command ({1})", "error_not_owner": "{0} tried to use a bot admin command ({1})",
"error_not_owner_unknown": "Unknown", "error_not_owner_unknown": "Unknown",
"error_nsfw_channel_required_description": "this command can only be used in Age-Restricted (NSFW) channels.",
"error_out_of_time": "you ran out of time.", "error_out_of_time": "you ran out of time.",
"error_out_of_time_economy": "you ran out of time. Your bet was forfeited.", "error_out_of_time_economy": "you ran out of time. Your bet was forfeited.",
"error_private_message_only_author": "Private Message Only", "error_private_message_only_author": "Private Message Only",