show userhost as well as nickname in !maskfind output
This commit is contained in:
parent
c19d20dec2
commit
70be211a16
1 changed files with 5 additions and 3 deletions
|
@ -29,11 +29,13 @@ class Module(ModuleManager.BaseModule):
|
|||
searched += len(userhosts)
|
||||
for userhost in userhosts:
|
||||
if hostmask.match(userhost):
|
||||
nicknames.add(nickname)
|
||||
nicknames.add((nickname, userhost))
|
||||
|
||||
if nicknames:
|
||||
outs = []
|
||||
for nickname, userhost in sorted(nicknames):
|
||||
outs.append("%s (%s)" % (nickname, userhost))
|
||||
event["stdout"].write("%s (%d/%d): %s" %
|
||||
(hostmask_str, len(nicknames), searched,
|
||||
", ".join(sorted(nicknames))))
|
||||
(hostmask_str, len(nicknames), searched, ", ".join(outs)))
|
||||
else:
|
||||
event["stderr"].write("Hostmask not found")
|
||||
|
|
Loading…
Reference in a new issue