Skip to content

Commit 08cfdaa

Browse files
authored
fix
1 parent 3fead8d commit 08cfdaa

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

discord/client.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -553,7 +553,7 @@ async def on_view_error(
553553
This only fires for a view if you did not define its :func:`~discord.ui.View.on_error`.
554554
"""
555555

556-
print(f"Ignoring exception in view {self} for item {item}:", file=sys.stderr)
556+
print(f"Ignoring exception in view {interaction.view} for item {item}:", file=sys.stderr)
557557
traceback.print_exception(
558558
error.__class__, error, error.__traceback__, file=sys.stderr
559559
)
@@ -567,7 +567,7 @@ async def on_modal_error(self, error: Exception, interaction: Interaction) -> No
567567
This only fires for a modal if you did not define its :func:`~discord.ui.Modal.on_error`.
568568
"""
569569

570-
print(f"Ignoring exception in modal {self}:", file=sys.stderr)
570+
print(f"Ignoring exception in modal {interaction.modal}:", file=sys.stderr)
571571
traceback.print_exception(
572572
error.__class__, error, error.__traceback__, file=sys.stderr
573573
)

0 commit comments

Comments
 (0)