diff options
author | Matt Stratton <matt.stratton@gmail.com> | 2016-10-06 18:52:12 +0300 |
---|---|---|
committer | Matt Stratton <matt.stratton@gmail.com> | 2016-10-06 18:52:12 +0300 |
commit | e748d99ad955d36dc61e7b0c1fd00e64c7e3d74b (patch) | |
tree | b71c29ee4b5f0d02424cd2d158e644b3b71be59c /layouts/partials | |
parent | b127571c5ddf0f45fca9723ad2fa81988473fe2b (diff) |
Set proper publish date on episodes
Fixes #31
Diffstat (limited to 'layouts/partials')
-rw-r--r-- | layouts/partials/head/seo/open_graph.html | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/layouts/partials/head/seo/open_graph.html b/layouts/partials/head/seo/open_graph.html index 39d0b5a..a63eeac 100644 --- a/layouts/partials/head/seo/open_graph.html +++ b/layouts/partials/head/seo/open_graph.html @@ -37,7 +37,15 @@ {{ end }} <meta property="article:publisher" content="https://www.facebook.com/{{ .Site.Params.social.facebook }}" /> {{if .IsPage}} -<meta property="article:published_time" content="{{ .PublishDate }}" /> + {{ if isset .Params "PublishDate" }} + {{ if ne .PublishDate "" }} + <meta property="article:published_time" content="{{ .PublishDate }}" /> + {{ else }} + <meta property="article:published_time" content="{{ .Date }}" /> + {{ end }} + {{ else }} + <meta property="article:published_time" content="{{ .Date }}" /> + {{ end }} {{ end }} <meta property="article:modified_time" content="{{ .Date }}" /> <meta property="article:section" content="{{ .Section }}" /> |