Skip to content

Commit f42040d

Browse files
committed
Only show author image when set
Fixes `{nil, "picture"=>nil"}` in `_layouts/about.html` when author image isn't set in `_config.yml`. Close #34
1 parent e3f6e83 commit f42040d

File tree

3 files changed

+11
-2
lines changed

3 files changed

+11
-2
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,11 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](http://keepachangelog.com/)
66
and this project adheres to [Semantic Versioning](http://semver.org/).
77

8+
## [Unreleased] -
9+
10+
### Fixed
11+
- Fixed `{nil, "picture"=>nil"}` in `_layouts/about.html` when author image isn't set. [#34](https://github.com/mmistakes/jekyll-theme-basically-basic/issues/34)
12+
813
## [1.1.2] - 2017-09-14
914

1015
### Fixed

_layouts/about.html

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,9 @@
1212
</div>
1313
<aside class="entry-sidebar">
1414
{% include author %}
15-
<img class="author-picture" src="{{ author_picture }}" alt="{{ author_name }}">
15+
{% if author_picture %}
16+
<img class="author-picture" src="{{ author_picture }}" alt="{{ author_name }}">
17+
{% endif %}
1618
</aside>
1719
</div>
1820

docs/_layouts/about.html

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,9 @@
1212
</div>
1313
<aside class="entry-sidebar">
1414
{% include author %}
15-
<img class="author-picture" src="{{ author_picture }}" alt="{{ author_name }}">
15+
{% if author_picture %}
16+
<img class="author-picture" src="{{ author_picture }}" alt="{{ author_name }}">
17+
{% endif %}
1618
</aside>
1719
</div>
1820

0 commit comments

Comments
 (0)