From 1405057096c3d9c1b721ed4183bce909c5c28f9d Mon Sep 17 00:00:00 2001 From: Johann Bauer Date: Wed, 9 Nov 2016 18:07:25 +0100 Subject: [PATCH] Fix getting the number of watched addresses Resolves #13 --- server/protocol.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/protocol.py b/server/protocol.py index 0ea78f6..5f5ae54 100644 --- a/server/protocol.py +++ b/server/protocol.py @@ -331,8 +331,8 @@ class ElectrumX(JSONRPC): @classmethod def watched_address_count(cls): - sessions = self.SESSION_MGR.sessions - return sum(len(session.hash168s) for session in session + sessions = cls.SESSION_MGR.sessions + return sum(len(session.hash168s) for session in sessions if isinstance(session, cls)) @classmethod