From 2cf8a2217d03e9e3ee0d5365be32617c5058034c Mon Sep 17 00:00:00 2001 From: Jakub Kuczys Date: Sun, 17 Mar 2024 02:47:48 +0100 Subject: [PATCH] Add usage to existing code --- redbot/core/commands/help.py | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/redbot/core/commands/help.py b/redbot/core/commands/help.py index 66920780d59a..f2e2899e4a67 100644 --- a/redbot/core/commands/help.py +++ b/redbot/core/commands/help.py @@ -878,14 +878,10 @@ async def send_pages( m = await (destination.send(embed=pages[0]) if embed else destination.send(pages[0])) c = menus.DEFAULT_CONTROLS if len(pages) > 1 else {"\N{CROSS MARK}": menus.close_menu} # Allow other things to happen during menu timeout/interaction. - if use_DMs: - menu_ctx = await ctx.bot.get_context(m) - # Monkeypatch so help listens for reactions from the original author, not the bot - menu_ctx.author = ctx.author - else: - menu_ctx = ctx asyncio.create_task( - menus.menu(menu_ctx, pages, c, message=m, timeout=help_settings.react_timeout) + menus.menu( + ctx, pages, c, user=ctx.author, message=m, timeout=help_settings.react_timeout + ) ) # menu needs reactions added manually since we fed it a message menus.start_adding_reactions(m, c.keys())