diff --git a/_layouts/post_by_category.html b/_layouts/post_by_category.html index 057e4e2..05b4d05 100644 --- a/_layouts/post_by_category.html +++ b/_layouts/post_by_category.html @@ -39,7 +39,17 @@ layout: default {% endif %} {% endif %} --> - + {% if post.author %} + {% assign author = site.data.authors[post.author] %} + {% if author %} + {% assign author_name = author.name %} + {% else %} + {% assign author_name = post.author %} + {% endif %} + {% else %} + {% assign author_name = site.title %} + {% endif %} +

{{ post.title }} @@ -50,7 +60,7 @@ layout: default

{% endif %}
-

Posted by {% if post.author %}{{ post.author }}{% else %}{{ site.title }}{% endif %} on {{ post.date | date: "%B %-d, %Y" }}

+

Posted by {{ author_name }} on {{ post.date | date: "%B %-d, %Y" }}


diff --git a/_layouts/post_by_tag.html b/_layouts/post_by_tag.html index 073b9da..2139d30 100644 --- a/_layouts/post_by_tag.html +++ b/_layouts/post_by_tag.html @@ -39,7 +39,17 @@ layout: default {% endif %} {% endif %} --> - + {% if post.author %} + {% assign author = site.data.authors[post.author] %} + {% if author %} + {% assign author_name = author.name %} + {% else %} + {% assign author_name = post.author %} + {% endif %} + {% else %} + {% assign author_name = site.title %} + {% endif %} +

{{ post.title }} @@ -50,7 +60,7 @@ layout: default

{% endif %}
-

Posted by {% if post.author %}{{ post.author }}{% else %}{{ site.title }}{% endif %} on {{ post.date | date: "%B %-d, %Y" }}

+

Posted by {{ author_name }} on {{ post.date | date: "%B %-d, %Y" }}