blob: 046b61489983185926eab26a3427b010325a1f2a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
import discord
from discord import app_commands
from discord.ext.commands.errors import *
class Tree(app_commands.CommandTree):
async def on_error(
self,
interaction: discord.Interaction,
error: app_commands.AppCommandError,
):
if isinstance(error, CommandNotFound):
return
else:
raise error
|