fix get_nodes not being a public method

* fix get_nodes being a public method
This commit is contained in:
nico 2020-06-25 00:45:21 +02:00
parent bf05b826a1
commit 86562276d4
Signed by: mightyBroccoli
GPG Key ID: EA7C31AAB1BDC1A2
1 changed files with 2 additions and 2 deletions

View File

@ -190,7 +190,7 @@ class EjabberdMetrics(EjabberdApiCalls):
return data return data
def _get_nodes(self): def get_nodes(self):
if not hasattr(self, "_nodes"): if not hasattr(self, "_nodes"):
self._nodes = self.fetch_nodes() self._nodes = self.fetch_nodes()
return self._nodes return self._nodes
@ -228,7 +228,7 @@ class EjabberdMetrics(EjabberdApiCalls):
data["vhosts"] = vhosts data["vhosts"] = vhosts
nodes = {} nodes = {}
for node in self._get_nodes(): for node in self.get_nodes():
nodes[node] = self.get_node_metrics(node) nodes[node] = self.get_node_metrics(node)
data["online_client_by_ipversion"] = self.get_online_client_by_ipversion() data["online_client_by_ipversion"] = self.get_online_client_by_ipversion()