{% set user = session_user () %} {# Number of new messages #} {% if user %} {% set unread_messages = new_messages (user.id) %} {% endif %}