Make ordering in {% setcontent %}
more robust
#1186
Merged
{% setcontent %}
more robust
#1186