Skip to content

Commit 339a34c

Browse files
authored
FIX: post extra class condition.
1 parent a6ac931 commit 339a34c

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

layout/_macro/post.swig

+3-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,9 @@
33
{% set headlessPost = Array.prototype.indexOf.call(['quote', 'picture'], post.type) > -1 %}
44

55
{% set post_class = 'post post-type-' + post.type | default('normal') %}
6-
{% set post_class = post_class + ' ' + post_extra_class | default('') %}
6+
{% if post_extra_class > 0 %}
7+
{% set post_class = post_class + ' ' + post_extra_class | default('') %}
8+
{% endif %}
79
{% if post.sticky > 0 %}
810
{% set post_class = post_class + ' ' + 'post-sticky' %}
911
{% endif %}

0 commit comments

Comments
 (0)