1👍
✅
I believe there’s a syntax error in your code that passed by unnoticed:
{% else % }
should be:
{% else %}
Django template system probably looks for a regex {%...%}
, and as that didn’t match, it was regarded simply as text inside the {% if %}{% endif %}
node.
Source:stackexchange.com