From 51166271ff79acb2f15f6060505f65de688adf9d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Yves=20M=C3=BCller?= Date: Thu, 26 Sep 2013 11:00:08 +0200 Subject: templates: increase stability against malformed templates --- templates/host.html | 9 ++++++--- templates/index.html | 2 ++ 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/templates/host.html b/templates/host.html index bf30fd2..9fa1b82 100644 --- a/templates/host.html +++ b/templates/host.html @@ -55,7 +55,9 @@ +
+ {% if addresses %} {% for group in addresses | select_with_attribute('vserver', False) | groupby('interface') %}

{{ group.grouper }}

@@ -70,6 +72,7 @@ {% else %}

no network interfaces

{% endfor %} + {% endif %}
@@ -83,6 +86,7 @@ + {% set ports = ports or [] %} {% for port in ports %} {{port['port']}} @@ -97,8 +101,8 @@
- {% if services is defined %}
+ {% if services is defined %} @@ -135,9 +139,8 @@ {% endfor %}
+ {% endif %}
- {% endif %} -