{% set information = information is iterable ? information : (information is empty ? [] : [information]) %} {% set messages = messages is iterable ? messages : (messages is empty ? [] : [messages]) %} {% set warnings = warnings is iterable ? warnings : (warnings is empty ? [] : [warnings]) %} {% set errors = errors is iterable ? errors : (errors is empty ? [] : [errors]) %} {% set info = information|default([]) %} {% set msgs = messages|default([]) %} {% set warns = warnings|default([]) %} {% set errs = errors|default([]) %} {# INFO #} {% if info is iterable and info|length %}
{% for it in info %} {% endfor %}
{% endif %} {# SUCCESS #} {% if msgs is iterable and msgs|length %}
{% for m in msgs %} {% endfor %}
{% endif %} {# WARNINGS #} {% if warns is iterable and warns|length %}
{% for w in warns %} {% endfor %}
{% endif %} {# ERRORS #} {% if errs is iterable and errs|length %}
{% for e in errs %} {% endfor %}
{% endif %}