Fix empty RSSLink

This commit is contained in:
badele 2017-11-26 21:45:12 +01:00
parent ebfb6b8780
commit 2d5a6fb059
2 changed files with 8 additions and 0 deletions

View File

@ -17,7 +17,11 @@
{{ end }} {{ end }}
{{ if .Site.Params.rss }} {{ if .Site.Params.rss }}
<li> <li>
{{ if .RSSLink }}
<a href="{{ .RSSLink }}" title="RSS"> <a href="{{ .RSSLink }}" title="RSS">
{{ else }}
<a href="{{ .Site.RSSLink }}" title="RSS">
{{ end }}
<span class="fa-stack fa-lg"> <span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i> <i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-rss fa-stack-1x fa-inverse"></i> <i class="fa fa-rss fa-stack-1x fa-inverse"></i>

View File

@ -37,7 +37,11 @@
{{ .Hugo.Generator -}} {{ .Hugo.Generator -}}
<!-- Links and stylesheets --> <!-- Links and stylesheets -->
<link rel="canonical" href="{{ .URL | absLangURL }}" /> <link rel="canonical" href="{{ .URL | absLangURL }}" />
{{- if .RSSLink }}
<link rel="alternate" href="{{ .RSSLink }}" type="application/rss+xml" title="{{ .Site.Title }}"> <link rel="alternate" href="{{ .RSSLink }}" type="application/rss+xml" title="{{ .Site.Title }}">
{{- else }}
<link rel="alternate" href="{{ .Site.RSSLink }}" type="application/rss+xml" title="{{ .Site.Title }}">
{{- end }}
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.7.1/katex.min.css" integrity="sha384-wITovz90syo1dJWVh32uuETPVEtGigN07tkttEqPv+uR2SE/mbQcG7ATL28aI9H0" crossorigin="anonymous"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.7.1/katex.min.css" integrity="sha384-wITovz90syo1dJWVh32uuETPVEtGigN07tkttEqPv+uR2SE/mbQcG7ATL28aI9H0" crossorigin="anonymous">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css" /> <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css" />
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous"> <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">