Skip to content

Commit c432ae2

Browse files
committed
mapping.j2: fixed handling of OrderedDict in Python 3
1 parent 84c6426 commit c432ae2

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

postfix/files/mapping.j2

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
{%- else %}
2222
{#- Some settings need order, handle OrderedDict #}
2323
{% for item in data %}
24-
{{ format_value(item.keys()[0], item.values()[0]) }}
24+
{%- set key, value = item.popitem() %}
25+
{{ format_value(key, value) }}
2526
{%- endfor -%}
2627
{%- endif %}

0 commit comments

Comments
 (0)