mirror of
https://github.com/Fluffy-Bean/Lynxie.git
synced 2025-05-19 09:54:53 +00:00
style: format code with black
Format code with black
This commit fixes the style issues introduced in 7b7f300
according to the output
from Black.
Details: None
This commit is contained in:
parent
7b7f30067b
commit
f516ebf519
2 changed files with 29 additions and 29 deletions
|
@ -33,7 +33,9 @@ class Img(commands.Cog):
|
|||
elif ctx.message.embeds and ctx.message.embeds[0].image:
|
||||
image_attachments = ctx.message.embeds[0].image
|
||||
else:
|
||||
async for message in ctx.guild.get_channel(ctx.channel.id).history(limit=10):
|
||||
async for message in ctx.guild.get_channel(ctx.channel.id).history(
|
||||
limit=10
|
||||
):
|
||||
if message.attachments:
|
||||
image_attachments = message.attachments[0]
|
||||
break
|
||||
|
@ -70,8 +72,7 @@ class Img(commands.Cog):
|
|||
return
|
||||
elif (
|
||||
image_attachments.url
|
||||
and not image_attachments.url.split(".")[-1].lower()
|
||||
in IMAGE_EXTENSIONS
|
||||
and not image_attachments.url.split(".")[-1].lower() in IMAGE_EXTENSIONS
|
||||
):
|
||||
error = (
|
||||
"Unsupported file type! Supported file types are:\n"
|
||||
|
@ -80,10 +81,7 @@ class Img(commands.Cog):
|
|||
await ctx.reply(embed=error_message(error))
|
||||
return
|
||||
|
||||
if (
|
||||
image_attachments.size
|
||||
and image_attachments.size > 8 * 1024 * 1024
|
||||
):
|
||||
if image_attachments.size and image_attachments.size > 8 * 1024 * 1024:
|
||||
error = (
|
||||
"That image is too big! Please use an image that is less than 8MB."
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue