future image

This commit is contained in:
Roy Olav Purser 2021-05-27 20:51:50 +02:00
parent 5969e24128
commit c8a4be5897
Signed by: roypur
GPG Key ID: E14D26A036F21656

View File

@ -230,13 +230,13 @@ class UpstreamHandler():
image_status_full_future = None image_status_full_future = None
if full_image != image: if full_image != image:
image_status_full_future = session.head(full_image) image_status_full_future = session.head(full_image)
if full_image != image: if standard_image != image:
image_status_standard_future = session.head(standard_image) image_status_standard_future = session.head(standard_image)
image_status_full = None image_status_full = None
image_status_standard = None image_status_standard = None
if image_status_standard_future != None: if image_status_standard_future is not None:
image_status_standard = await image_status_standard_future image_status_standard = await image_status_standard_future
if image_status_full_future != None: if image_status_full_future is not None:
image_status_full = await image_status_full_future image_status_full = await image_status_full_future
if hasattr(image_status_full, "status") and (image_status_full.status < 400): if hasattr(image_status_full, "status") and (image_status_full.status < 400):
data["og:image"] = full_image data["og:image"] = full_image