Skip to content

Commit

Permalink
add if statement for addition of alt text to avatar
Browse files Browse the repository at this point in the history
  • Loading branch information
bmos committed Mar 16, 2024
1 parent ef32044 commit 86decc6
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions _includes/avatar.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
<img height="{{include.height}}"
width="{{include.width}}"
class="{{include.class}}"
{% if post.author and post.avatar %}
alt="the logo of {{post.author}}"
{% endif %}
src="{% if post.avatar contains '://' %}{% elsif post.avatar %}{{ site.baseurl }}/hackergotchi/{% else %}{{ site.baseurl }}/hackergotchi/default.png{% endif %}{{ post.avatar }}"/>

0 comments on commit 86decc6

Please sign in to comment.