upload_dino command
This commit is contained in:
parent
cbd19659b0
commit
79c5f0cf5a
@ -15,7 +15,7 @@ class Uploader:
|
|||||||
@commands.command(name='upload', aliases=['submit'])
|
@commands.command(name='upload', aliases=['submit'])
|
||||||
async def upload_dino(self, ctx, official: str='unofficial', singleplayer: bool=False):
|
async def upload_dino(self, ctx, official: str='unofficial', singleplayer: bool=False):
|
||||||
if ctx.message.attachments:
|
if ctx.message.attachments:
|
||||||
attachment = ctx.message.attachements[0]
|
attachment = ctx.message.attachments[0]
|
||||||
if attachment.filename.endswith('.zip'):
|
if attachment.filename.endswith('.zip'):
|
||||||
with BytesIO() as file:
|
with BytesIO() as file:
|
||||||
await attachment.save(file)
|
await attachment.save(file)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user