forked from cswimr/SeaCogs
fix(backup): fixed list out of index error
This commit is contained in:
parent
045d51bc23
commit
26b085231b
1 changed files with 1 additions and 1 deletions
|
@ -61,7 +61,7 @@ class Backup(commands.Cog):
|
|||
async def backup_import(self, ctx: commands.Context, json: str = None):
|
||||
"""Import your installed repositories and cogs from an export."""
|
||||
if json is None:
|
||||
if ctx.message.attachments is not None:
|
||||
if not len(ctx.message.attachments) == 0:
|
||||
json = await ctx.message.attachments[0].read()
|
||||
else:
|
||||
await ctx.send(error("Please provide a valid JSON export."))
|
||||
|
|
Loading…
Reference in a new issue