From a05b7b5cd81cb83d187666007b425e168059f803 Mon Sep 17 00:00:00 2001 From: Mantas VilĨinskas Date: Fri, 1 Dec 2023 14:06:00 +0200 Subject: checks if post is explicitly set to not be pinned contributed by MirMiz --- layouts/partials/index/announcements.html | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'layouts/partials/index') diff --git a/layouts/partials/index/announcements.html b/layouts/partials/index/announcements.html index 2bb7f08..389d673 100644 --- a/layouts/partials/index/announcements.html +++ b/layouts/partials/index/announcements.html @@ -1,5 +1,7 @@ {{ $allPosts := where .Site.RegularPages "Params.section" "issue" }} -{{ $active := where $allPosts "Params.resolved" "=" false }} +{{ $allActive := where $allPosts "Params.resolved" "=" false }} +{{ $active := where $allActive "Params.pin" "!=" false }} +{{/* this $active checks if pin is explicitely set to false */}} {{ $informationals := where $allPosts "Params.informational" "=" true }} {{ $pinned := where $informationals "Params.pin" "=" true }} -- cgit v1.2.3-70-g09d2