mirror of
https://github.com/stijndcl/didier.git
synced 2026-04-07 15:48:29 +02:00
Add custom error handler to test function so it doesn't spam everything in #Error-Logs all the time but prints them in your terminal
This commit is contained in:
parent
1f685bfbe9
commit
ed07d41544
1 changed files with 4 additions and 0 deletions
|
|
@ -15,6 +15,10 @@ class TestCog(commands.Cog):
|
||||||
async def test(self, ctx):
|
async def test(self, ctx):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
@test.error
|
||||||
|
async def test_handler(self, ctx, error):
|
||||||
|
raise error
|
||||||
|
|
||||||
|
|
||||||
def setup(client):
|
def setup(client):
|
||||||
client.add_cog(TestCog(client))
|
client.add_cog(TestCog(client))
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue