mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-11-06 11:18:54 -05:00
Check to avoid an IndexError (#5429)
This commit is contained in:
parent
3f4842603b
commit
6c4e5af5ee
@ -37,6 +37,10 @@ class QueueCommands(MixinMeta, metaclass=CompositeMetaClass):
|
||||
async def command_queue(self, ctx: commands.Context, *, page: int = 1):
|
||||
"""List the songs in the queue."""
|
||||
|
||||
# Check to avoid an IndexError further down in the code.
|
||||
if page < 1:
|
||||
page = 1
|
||||
|
||||
async def _queue_menu(
|
||||
ctx: commands.Context,
|
||||
pages: list,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user