Skip to content

Commit

Permalink
tpl: Remove RSS deprecation site.Author check
Browse files Browse the repository at this point in the history
The check itself creates a warning which I guess was not intended.

We could possibly make that work, but it has been deprecated since Hugo 0.98, so just remove the usage.
  • Loading branch information
bep committed Sep 19, 2024
1 parent 22a9f3f commit e07028c
Showing 1 changed file with 0 additions and 12 deletions.
12 changes: 0 additions & 12 deletions tpl/tplimpl/embedded/templates/_default/rss.xml
Original file line number Diff line number Diff line change
@@ -1,19 +1,12 @@
{{- /* Deprecate site.Author.email in favor of site.Params.author.email */}}
{{- $authorEmail := "" }}
{{- with site.Params.author }}
{{- if reflect.IsMap . }}
{{- with .email }}
{{- $authorEmail = . }}
{{- end }}
{{- end }}
{{- else }}
{{- with site.Author.email }}
{{- $authorEmail = . }}
{{- warnf "The author key in site configuration is deprecated. Use params.author.email instead." }}
{{- end }}
{{- end }}

{{- /* Deprecate site.Author.name in favor of site.Params.author.name */}}
{{- $authorName := "" }}
{{- with site.Params.author }}
{{- if reflect.IsMap . }}
Expand All @@ -23,11 +16,6 @@
{{- else }}
{{- $authorName = . }}
{{- end }}
{{- else }}
{{- with site.Author.name }}
{{- $authorName = . }}
{{- warnf "The author key in site configuration is deprecated. Use params.author.name instead." }}
{{- end }}
{{- end }}

{{- $pctx := . }}
Expand Down

0 comments on commit e07028c

Please sign in to comment.