Fixed save_image function

This commit is contained in:
phixxy 2023-07-12 15:14:30 -07:00
parent 4a5de660d7
commit 808013b29f

View file

@ -69,6 +69,10 @@ async def save_image(ctx):
imageName = "blank_image.png"
with open(imageName, 'wb') as out_file:
print(f"Saving image: {imageName}")
shutil.copyfileobj(r.raw, out_file)
if os.path.exists(imageName):
await ctx.send("Saved Image!")
else: