diff options
Diffstat (limited to 'tpl/tplimpl/template_embedded.go')
-rw-r--r-- | tpl/tplimpl/template_embedded.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tpl/tplimpl/template_embedded.go b/tpl/tplimpl/template_embedded.go index b54a4bbec..627d4dc4d 100644 --- a/tpl/tplimpl/template_embedded.go +++ b/tpl/tplimpl/template_embedded.go @@ -233,18 +233,18 @@ func (t *templateHandler) embedTemplates() { t.addInternalTemplate("", "twitter_cards.html", `{{- with $.Params.images -}} <meta name="twitter:card" content="summary_large_image"/> -<meta name="twitter:image:src" content="{{ index . 0 | absURL }}"/> +<meta name="twitter:image" content="{{ index . 0 | absURL }}"/> {{ else -}} {{- $images := $.Resources.ByType "image" -}} {{- $featured := $images.GetMatch "*feature*" -}} {{- $featured := cond (ne $featured nil) $featured ($images.GetMatch "{*cover*,*thumbnail*}") -}} {{- with $featured -}} <meta name="twitter:card" content="summary_large_image"/> -<meta name="twitter:image:src" content="{{ $featured.Permalink }}"/> +<meta name="twitter:image" content="{{ $featured.Permalink }}"/> {{- else -}} {{- with $.Site.Params.images -}} <meta name="twitter:card" content="summary_large_image"/> -<meta name="twitter:image:src" content="{{ index . 0 | absURL }}"/> +<meta name="twitter:image" content="{{ index . 0 | absURL }}"/> {{ else -}} <meta name="twitter:card" content="summary"/> {{- end -}} |