From 3242d892b56a1ddb0a9249bb199ac13e1c05245a Mon Sep 17 00:00:00 2001 From: BBaoVanC Date: Sat, 9 Oct 2021 18:31:05 -0500 Subject: [PATCH] Update og:video code --- layouts/partials/opengraph.html | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/layouts/partials/opengraph.html b/layouts/partials/opengraph.html index 4a947d2..6020b97 100644 --- a/layouts/partials/opengraph.html +++ b/layouts/partials/opengraph.html @@ -27,15 +27,15 @@ {{- with .Params.locale }}{{ end }} {{- with .Site.Params.title }}{{ end }} +{{- with .Params.videos -}} +{{- range first 6 . }}{{ end -}} +{{- else -}} {{- $videos := $.Resources.ByType "video" -}} {{- $featured_video := $videos.GetMatch "*feature*" -}} {{- if not $featured_video }}{{ $featured_video = $videos.GetMatch "{*cover*,*thumbnail*}" }}{{ end -}} {{- with $featured_video -}} -{{- else -}} -{{- with .Params.videos }}{{- range . }} - -{{ end }}{{ end }} +{{- end -}} {{- end -}} {{- /* If it is part of a series, link to related articles */}}