remotes/1693045480750635534/spooky-22
Aevann1 2021-09-13 18:38:30 +02:00
parent 50b2f06fc2
commit 5b0c0e0b21
2 changed files with 3 additions and 3 deletions

View File

@ -527,7 +527,7 @@ def thumbs(new_post):
for chunk in image_req.iter_content(1024):
file.write(chunk)
if 'pcmemes.ga' in request.host: post.thumburl = upload_ibb(filepath="image.webp", resize=True)
if 'pcmemes.ga' in request.host: post.thumburl = upload_ibb(resize=True)
else: post.thumburl = upload_imgur(filepath="image.webp", resize=True)
g.db.add(post)

View File

@ -505,11 +505,11 @@ def settings_images_profile(v):
filepath = f"image.{format}"
file.save(filepath)
if 'pcmemes.ga' in request.host: highres = upload_ibb(filepath=filepath)
if 'pcmemes.ga' in request.host: highres = upload_ibb()
else: highres = upload_imgur(filepath=filepath)
if not highres: abort(400)
if 'pcmemes.ga' in request.host: imageurl = upload_ibb(filepath=filepath, resize=True)
if 'pcmemes.ga' in request.host: imageurl = upload_ibb(resize=True)
else: imageurl = upload_imgur(filepath=filepath, resize=True)
if not imageurl: abort(400)