removed same article from related

This commit is contained in:
Gabriele Musco 2021-04-15 10:07:42 +02:00
parent 0c80aa9ee5
commit e7257ec518
No known key found for this signature in database
GPG Key ID: 8539FD3454380B83
1 changed files with 4 additions and 2 deletions

View File

@ -1,8 +1,10 @@
{{ if and (.Site.Params.enableRelatedArticles | default false) .Params.tags }} {{ if and (.Site.Params.enableRelatedArticles | default false) .Params.tags }}
{{ $postsList := {{ $postsList :=
where ( where (
where site.RegularPages "Params.tags" "!=" nil where (
) "Params.tags" "intersect" .Params.tags where site.RegularPages "Params.tags" "!=" nil
) "Params.tags" "intersect" .Params.tags
) "Permalink" "ne" .Permalink
}} }}
<div class="relatedArticlesContainer"> <div class="relatedArticlesContainer">
<hr /> <hr />