From e28812f14471dd59188b06bc6a5ad909857f11d2 Mon Sep 17 00:00:00 2001
From: Aditi Juneja <91629733+Schefflera-Arboricola@users.noreply.github.com>
Date: Mon, 11 Mar 2024 19:50:14 +0530
Subject: [PATCH 1/2] fixed `showOnTop`
---
layouts/partials/posts/post.html | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/layouts/partials/posts/post.html b/layouts/partials/posts/post.html
index 36c48ce8..bb8420a4 100644
--- a/layouts/partials/posts/post.html
+++ b/layouts/partials/posts/post.html
@@ -8,9 +8,9 @@
{{ partial "posts/meta.html" . }}
- {{ with $featuredImage }}
+ {{ if and $featuredImage $featuredImage.Params.showOnTop }}
-

+
{{ end }}
{{ .Content }}
From 7652ac1b4c89b3cfb0689aecef525307a8563b80 Mon Sep 17 00:00:00 2001
From: Stefan van der Walt
Date: Mon, 11 Mar 2024 13:56:26 -0700
Subject: [PATCH 2/2] Use with statement
---
layouts/partials/posts/post.html | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/layouts/partials/posts/post.html b/layouts/partials/posts/post.html
index bb8420a4..4c14b1d2 100644
--- a/layouts/partials/posts/post.html
+++ b/layouts/partials/posts/post.html
@@ -8,11 +8,13 @@ {{ .Params.Subtitle }}
{{ end }}
{{ partial "posts/meta.html" . }}
- {{ if and $featuredImage $featuredImage.Params.showOnTop }}
+ {{ with $featuredImage }}
+ {{ if .Params.showOnTop }}
-

+
{{ end }}
+ {{ end }}
{{ .Content }}
{{ partial "posts/comments.html" .}}