Fixed Inconsistent wrapping of <xf:likes in a $content.likes check

Xon

Well-known member
Affected version
2.0
The like bar on posts is defined as;
Code:
<div class="likesBar js-likeList {{ $post.likes ? 'is-active' : '' }}">
<xf:likes content="{$post}" url="{{ link('posts/likes', $post) }}" />
</div>
But elsewhere it is
Code:
<div class="likesBar js-likeList {{ $message.likes ? 'is-active' : '' }}"><xf:if is="$message.likes">
<xf:likes content="{$message}" url="{{ link('conversations/messages/likes', $message) }}" />
</xf:if></div>

The <xf:if is="$message.likes"> isn't required as <xf:likes /> does this itself.
 
Back
Top Bottom