From: Michael Tremer Date: Fri, 21 Oct 2016 21:04:19 +0000 (+0200) Subject: latency: Show "Default Gateway" in headline for gateway X-Git-Url: http://git.ipfire.org/?p=collecty.git;a=commitdiff_plain;h=69eeb1a3f2ef17f0a4d1a09c9d4ab7554ab6418e latency: Show "Default Gateway" in headline for gateway Signed-off-by: Michael Tremer --- diff --git a/src/collecty/plugins/latency.py b/src/collecty/plugins/latency.py index 0ef70eb..43ae475 100644 --- a/src/collecty/plugins/latency.py +++ b/src/collecty/plugins/latency.py @@ -107,7 +107,13 @@ class GraphTemplateLatency(base.GraphTemplate): @property def graph_title(self): _ = self.locale.translate - return _("Latency to %s") % self.object.hostname + + if self.object.hostname == "gateway": + hostname = _("Default Gateway") + else: + hostname = self.object.hostname + + return _("Latency to %s") % hostname @property def graph_vertical_label(self):