{% with avatar_url=user.avatar_url %}
{% if not avatar_url %} {{ user.get_full_name.0|default:user.get_username.0|upper }} {% endif %}
{% endwith %}