From 9d23167be7642d6ee189ea85c51a06bb17373440 Mon Sep 17 00:00:00 2001 From: N-Upchurch Date: Mon, 21 Aug 2023 19:21:48 -0500 Subject: [PATCH] Add default author if none specified in post --- _includes/layouts/post.njk | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/_includes/layouts/post.njk b/_includes/layouts/post.njk index 6840566..0623230 100644 --- a/_includes/layouts/post.njk +++ b/_includes/layouts/post.njk @@ -5,13 +5,15 @@ layout: layouts/base.njk {%- css %}{% include "public/css/code.css" %}{% endcss %}

{{ title }}

- +
+

{% if author.name %}{{ author.name }}, {% else %}{{ metadata.author.name }}, {% endif %}

+ +
{{ content | safe }}