mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-12-05 17:02:32 -05:00
Remove usage of loop arg in calls to start_adding_reactions (#3644)
* fix stacklevels of warnings * stop using loop arg when calling start_adding_reactions * [Audio] Stop using loop arg when calling start_adding_reactions
This commit is contained in:
@@ -2001,7 +2001,7 @@ class Audio(commands.Cog):
|
||||
with contextlib.suppress(discord.HTTPException):
|
||||
await eq_message.add_reaction("\N{INFORMATION SOURCE}")
|
||||
else:
|
||||
start_adding_reactions(eq_message, reactions, self.bot.loop)
|
||||
start_adding_reactions(eq_message, reactions)
|
||||
|
||||
eq_msg_with_reacts = await ctx.fetch_message(eq_message.id)
|
||||
player.store("eq_message", eq_msg_with_reacts)
|
||||
@@ -2605,7 +2605,7 @@ class Audio(commands.Cog):
|
||||
if not player.queue:
|
||||
expected = ("⏹", "⏯")
|
||||
if player.current:
|
||||
task = start_adding_reactions(message, expected[:4], ctx.bot.loop)
|
||||
task = start_adding_reactions(message, expected[:4])
|
||||
else:
|
||||
task = None
|
||||
|
||||
@@ -6334,7 +6334,7 @@ class Audio(commands.Cog):
|
||||
expected = ("⏹", "⏯")
|
||||
emoji = {"stop": "⏹", "pause": "⏯"}
|
||||
if player.current:
|
||||
task = start_adding_reactions(message, expected[:4], ctx.bot.loop)
|
||||
task = start_adding_reactions(message, expected[:4])
|
||||
else:
|
||||
task = None
|
||||
|
||||
|
||||
@@ -1286,7 +1286,7 @@ class Downloader(commands.Cog):
|
||||
query: discord.Message = await ctx.send(message)
|
||||
if can_react:
|
||||
# noinspection PyAsyncCall
|
||||
start_adding_reactions(query, ReactionPredicate.YES_OR_NO_EMOJIS, ctx.bot.loop)
|
||||
start_adding_reactions(query, ReactionPredicate.YES_OR_NO_EMOJIS)
|
||||
pred = ReactionPredicate.yes_or_no(query, ctx.author)
|
||||
event = "reaction_add"
|
||||
else:
|
||||
|
||||
@@ -645,7 +645,7 @@ class Permissions(commands.Cog):
|
||||
if ctx.guild is None or ctx.guild.me.permissions_in(ctx.channel).add_reactions:
|
||||
msg = await ctx.send(_("Are you sure?"))
|
||||
# noinspection PyAsyncCall
|
||||
task = start_adding_reactions(msg, ReactionPredicate.YES_OR_NO_EMOJIS, ctx.bot.loop)
|
||||
task = start_adding_reactions(msg, ReactionPredicate.YES_OR_NO_EMOJIS)
|
||||
pred = ReactionPredicate.yes_or_no(msg, ctx.author)
|
||||
try:
|
||||
await ctx.bot.wait_for("reaction_add", check=pred, timeout=30)
|
||||
|
||||
Reference in New Issue
Block a user