Avoid doing pointless lookups against numbered networks
This commit is contained in:
@@ -10,7 +10,7 @@ def getWhoSingle(name, query):
|
||||
|
||||
def getWho(query):
|
||||
result = {}
|
||||
for i in main.pool.keys():
|
||||
for i in main.nets():
|
||||
f = getWhoSingle(i, query)
|
||||
if f:
|
||||
result[i] = f
|
||||
@@ -25,7 +25,7 @@ def getChansSingle(name, nick):
|
||||
|
||||
def getChans(nick):
|
||||
result = {}
|
||||
for i in main.pool.keys():
|
||||
for i in main.nets():
|
||||
f = getChansSingle(i, nick)
|
||||
if f:
|
||||
result[i] = f
|
||||
@@ -40,7 +40,7 @@ def getUsersSingle(name, nick):
|
||||
|
||||
def getUsers(nick):
|
||||
result = {}
|
||||
for i in main.pool.keys():
|
||||
for i in main.nets():
|
||||
f = getUsersSingle(i, nick)
|
||||
if f:
|
||||
result[i] = f
|
||||
@@ -51,7 +51,7 @@ def getNumWhoEntries(name):
|
||||
|
||||
def getNumTotalWhoEntries():
|
||||
total = 0
|
||||
for i in main.pool.keys():
|
||||
for i in main.nets():
|
||||
total += getNumWhoEntries(i)
|
||||
return total
|
||||
|
||||
|
||||
Reference in New Issue
Block a user