diff options
author | tdro <tdro@noreply.example.com> | 2022-08-03 02:25:22 -0400 |
---|---|---|
committer | tdro <tdro@noreply.example.com> | 2022-08-03 02:25:22 -0400 |
commit | eec7f7ea5d99e84ef2a9cf4594b18d1046ae3038 (patch) | |
tree | c3c4d9af65d5ecb6e7f91a52b1dc79fe6ba605fc /themes/default/layouts/partials/author-list.html | |
parent | 93ff2963616968f377d63f02bb0fa206144da7ae (diff) | |
download | canory-eec7f7ea5d99e84ef2a9cf4594b18d1046ae3038.tar.gz canory-eec7f7ea5d99e84ef2a9cf4594b18d1046ae3038.tar.bz2 canory-eec7f7ea5d99e84ef2a9cf4594b18d1046ae3038.zip |
themes/default/layouts/partials/author-list: Dry up author's slice
Diffstat (limited to 'themes/default/layouts/partials/author-list.html')
-rw-r--r-- | themes/default/layouts/partials/author-list.html | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/themes/default/layouts/partials/author-list.html b/themes/default/layouts/partials/author-list.html index 127447f..37e3222 100644 --- a/themes/default/layouts/partials/author-list.html +++ b/themes/default/layouts/partials/author-list.html @@ -1,12 +1,9 @@ -{{ $authors := slice }} -{{ range $index, $data := .Site.Data -}} - {{- $authors = $authors | append $data.user -}} -{{- end -}} +{{- $authors := partial "function-authors-slice.html" . -}} <author-list> <h1>Authors</h1> <aside> - {{- range $author := first 3 (shuffle (uniq $authors)) -}} + {{- range $author := first 3 (shuffle $authors) -}} {{ $data := index $.Site.Data $author | default "default" }} {{ partial "author-card.html" (dict "Data" $data) }} {{ end }} |