Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Translation update, slash commands errors handler added #134

Merged
merged 3 commits into from
Feb 18, 2024

Conversation

liner-exe
Copy link
Contributor

PR changes

  • Updated translation ru-ru.json
  • Added slash commands errors handler cogs/errors.py

@eibex
Copy link
Owner

eibex commented Feb 18, 2024

Hi, thanks for the PR! I left a comment before we can merge :) Would you mind making that change?

@liner-exe
Copy link
Contributor Author

liner-exe commented Feb 18, 2024

I don't got it

@eibex
Copy link
Owner

eibex commented Feb 18, 2024

I pushed a commit in the PR branch. It should work as intended now.

Thanks for spotting the issue on command errors not being captured.

cogs/errors.py Outdated
@@ -41,6 +41,14 @@ async def on_command_error(self, inter, error):
traceback.print_tb(error.__traceback__)
print(error)

@commands.Cog.listener()
async def on_slash_command_error(self, inter, error):
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be better to delete this block and transform the function above to on_slash_command_error instead of on_command_error since we only have slash commands.

@eibex eibex merged commit 47c948c into eibex:master Feb 18, 2024
2 checks passed
@liner-exe
Copy link
Contributor Author

You're welcome. Glad to help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants