We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8029089 commit 2941072Copy full SHA for 2941072
sphinxext/opengraph/__init__.py
@@ -128,6 +128,8 @@ def get_tags(
128
):
129
image_url = first_image["uri"]
130
ogp_image_alt = first_image.get("alt", None)
131
+ else:
132
+ first_image = None
133
134
if image_url:
135
# temporarily disable relative image paths with field lists
@@ -137,7 +139,7 @@ def get_tags(
137
139
# Relative image path detected, relative to the source. Make absolute.
138
140
if first_image:
141
root = page_url
- else:
142
+ else: # ogp_image is set
143
# ogp_image is defined as being relative to the site root.
144
# This workaround is to keep that functionality from breaking.
145
root = config["ogp_site_url"]
0 commit comments