From b82b547acb404cdb883154cc4991137d46caa22a Mon Sep 17 00:00:00 2001 From: Razon Yang Date: Tue, 6 Dec 2022 17:48:34 +0800 Subject: tpl/embedded: Make Open Graph's series optional --- tpl/tplimpl/embedded/templates/opengraph.html | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tpl/tplimpl/embedded/templates/opengraph.html b/tpl/tplimpl/embedded/templates/opengraph.html index e3961524b..a9d4dd83c 100644 --- a/tpl/tplimpl/embedded/templates/opengraph.html +++ b/tpl/tplimpl/embedded/templates/opengraph.html @@ -33,12 +33,14 @@ {{- /* If it is part of a series, link to related articles */}} {{- $permalink := .Permalink }} {{- $siteSeries := .Site.Taxonomies.series }} +{{- if $siteSeries }} {{ with .Params.series }}{{- range $name := . }} {{- $series := index $siteSeries ($name | urlize) }} {{- range $page := first 6 $series.Pages }} {{- if ne $page.Permalink $permalink }}{{ end }} {{- end }} {{ end }}{{ end }} +{{- end }} {{- /* Facebook Page Admin ID for Domain Insights */}} {{- with .Site.Social.facebook_admin }}{{ end }} -- cgit v1.2.3