Don't show date information of post when no date is set
This commit is contained in:
parent
f7fbd1e7f2
commit
4633d08017
1 changed files with 3 additions and 2 deletions
|
|
@ -1,2 +1,3 @@
|
|||
{{ with $.Param "author" }}<span class="author" itemprop="author">{{ . }}</span> – {{ end -}}
|
||||
<time class="created-date" datetime="{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}">{{ .Date.Format ($.Param "dateformat" | default "2 January, 2006") }}</time>
|
||||
{{ with .Param "author" }}<span class="author" itemprop="author">{{ . }}</span>{{ end -}}
|
||||
{{ if and .Date (.Param "author") }} - {{ end -}}
|
||||
{{ with .Date }}<time class="created-date" datetime="{{ .Format "2006-01-02T15:04:05Z07:00" }}">{{ .Format ($.Param "dateformat" | default "2 January, 2006") }}</time>{{ end }}
|
||||
Loading…
Reference in a new issue