Update ban_enforce.py
This commit is contained in:
parent
84aa7d1bd5
commit
2d76365214
1 changed files with 4 additions and 3 deletions
|
@ -16,11 +16,12 @@ class Module(ModuleManager.BaseModule):
|
||||||
if mode[0] == "+" and mode[1] == "b":
|
if mode[0] == "+" and mode[1] == "b":
|
||||||
bans.append(arg)
|
bans.append(arg)
|
||||||
|
|
||||||
if bans:
|
|
||||||
affected = 0
|
affected = 0
|
||||||
umasks = {u.hostmask(): u for u in event["channel"].users}
|
|
||||||
defaultmax = len(event["channel"].users) // 2
|
defaultmax = len(event["channel"].users) // 2
|
||||||
realmax = event["channel"].get_setting("ban-enforce-max", defaultmax)
|
realmax = event["channel"].get_setting("ban-enforce-max", defaultmax)
|
||||||
|
|
||||||
|
if bans:
|
||||||
|
umasks = {u.hostmask(): u for u in event["channel"].users}
|
||||||
for ban in bans:
|
for ban in bans:
|
||||||
mask = utils.irc.hostmask_parse(ban)
|
mask = utils.irc.hostmask_parse(ban)
|
||||||
matches = list(utils.irc.hostmask_match_many(
|
matches = list(utils.irc.hostmask_match_many(
|
||||||
|
|
Loading…
Reference in a new issue