aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJordan <me@jordan.im>2019-06-25 23:35:39 -0700
committerJordan <me@jordan.im>2019-06-25 23:35:39 -0700
commit18648ffc8aa6e5a561358fc822cde752dc593cea (patch)
tree8207c09f5837ba110519092a24d8a86f189fdf38
parent8f3008432b3e8e960216143bebfebca6cfffd246 (diff)
downloadallium-18648ffc8aa6e5a561358fc822cde752dc593cea.tar.gz
allium-18648ffc8aa6e5a561358fc822cde752dc593cea.zip
use single conditional when checking member count
-rw-r--r--tor-metrics/templates/base.html5
1 files changed, 2 insertions, 3 deletions
diff --git a/tor-metrics/templates/base.html b/tor-metrics/templates/base.html
index a3f4560..4f75ab1 100644
--- a/tor-metrics/templates/base.html
+++ b/tor-metrics/templates/base.html
@@ -36,11 +36,10 @@
{% else %}
{% set obs_bandwidth = '%s %s'|format((relay['observed_bandwidth'] / 1000)|round(2, 'common'), 'KB/s') %}{% endif %}
- {% if category != 'family' %}
- {% if relay['effective_family']|length > 1 %}
+ {% if category != 'family' and relay['effective_family']|length > 1 %}
<td>{{ relay['nickname'] }} (<a href="{{ path_prefix }}family/{{ relay['effective_family'][0] }}/">{{ relay['effective_family']|length }}</a>)</td>
{% else %}
- <td>{{ relay['nickname'] }}</td>{% endif %}{% endif %}
+ <td>{{ relay['nickname'] }}</td>{% endif %}
<td>{{ obs_bandwidth }}</td>
<td class="visible-md visible-lg">{{ relay['or_addresses'][0].split(':', 1)[0] }}</td>