I'm trying to hide the new thread button if a users reaction is under 21. I thought this would work but it doesn't seem to and dumping the $user object just gets a null. Does someone know what I'm doing wrong?
Code:
<xf:pageaction if="$forum.canCreateThread() && $user.reaction_score|number > 20">
<xf:button href="{{ link('forums/post-thread', $forum) }}" class="button--cta" icon="write">
{{ phrase('post_thread') }}
</xf:button>
</xf:pageaction>