typo + authentication without IRCLogin
This commit is contained in:
parent
201baa636f
commit
d216d25096
|
@ -65,7 +65,7 @@ if cookie.has_key('sess'):
|
|||
|
||||
if not user:
|
||||
print "Sorry, bantracker has been shut down for anonymous users due to server load<br>"
|
||||
print "Join <a href=irc://irc.freenode.net/ubuntu-ops>#ubuntu-ops</a> on irc.freenode.net to descuss bans"
|
||||
print "Join <a href=irc://irc.freenode.net/ubuntu-ops>#ubuntu-ops</a> on irc.freenode.net to discuss bans"
|
||||
send_page('bans.tmpl')
|
||||
|
||||
# Log
|
||||
|
|
|
@ -419,8 +419,19 @@ class Bantracker(callbacks.Plugin):
|
|||
self(irc, m)
|
||||
return msg
|
||||
|
||||
def callPrecedence(self, irc):
|
||||
before = []
|
||||
for cb in irc.callbacks:
|
||||
if cb.name() == 'IRCLogin':
|
||||
before.append(cb)
|
||||
return (before, [])
|
||||
|
||||
def check_auth(self, irc, msg, args, cap='bantracker'):
|
||||
if not msg.tagged('identified'):
|
||||
hasIRCLogin = False
|
||||
for cb in self.callPrecedence(irc)[0]:
|
||||
if cb.name() == "IRCLogin":
|
||||
hasIRCLogin = True
|
||||
if hasIRCLogin and not msg.tagged('identified'):
|
||||
irc.error(conf.supybot.replies.incorrectAuthentication())
|
||||
return False
|
||||
try:
|
||||
|
|
Loading…
Reference in New Issue