mirror of
https://github.com/ncoevoet/ChanTracker.git
synced 2025-04-26 04:51:07 -05:00
fixs and added support for -capability protections
This commit is contained in:
parent
02f23df444
commit
7a4ff48863
@ -1048,7 +1048,7 @@ class Chan (object):
|
||||
c.execute("""DELETE FROM patterns WHERE id=? and channel=? LIMIT 1""",(uid,self.name))
|
||||
if uid in self.patterns:
|
||||
del self.patterns[uid]
|
||||
prop = 'Pattern%s' % pattern.uid
|
||||
prop = 'Pattern%s' % id
|
||||
if prop in self.spam:
|
||||
del self.spam[prop]
|
||||
db.commit()
|
||||
@ -3681,6 +3681,9 @@ class ChanTracker(callbacks.Plugin,plugins.ChannelDBHandler):
|
||||
limit = self.registryValue('%sPermit' % prop,channel=channel)
|
||||
if limit < 0:
|
||||
return False
|
||||
flag = ircdb.makeChannelCapability(channel, prop)
|
||||
if not ircdb.checkCapability(key, flag):
|
||||
return False
|
||||
chan = self.getChan(irc,channel)
|
||||
life = self.registryValue('%sLife' % prop,channel=channel)
|
||||
if not prop in chan.spam:
|
||||
|
Loading…
x
Reference in New Issue
Block a user