mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-30 14:59:34 +01:00
Made title snarfer not snarf if the URL is in an addressed message.
This commit is contained in:
parent
af0a4987f4
commit
4786631c6c
@ -99,12 +99,12 @@ class URL(callbacks.PrivmsgCommandAndRegexp,
|
|||||||
_titleRe = re.compile('<title>(.*?)</title>', re.I)
|
_titleRe = re.compile('<title>(.*?)</title>', re.I)
|
||||||
def __init__(self):
|
def __init__(self):
|
||||||
self.nextMsgs = {}
|
self.nextMsgs = {}
|
||||||
callbacks.PrivmsgCommandAndRegexp.__init__(self)
|
|
||||||
plugins.ChannelDBHandler.__init__(self)
|
plugins.ChannelDBHandler.__init__(self)
|
||||||
|
callbacks.PrivmsgCommandAndRegexp.__init__(self)
|
||||||
|
|
||||||
def die(self):
|
def die(self):
|
||||||
callbacks.PrivmsgCommandAndRegexp.die(self)
|
|
||||||
plugins.ChannelDBHandler.die(self)
|
plugins.ChannelDBHandler.die(self)
|
||||||
|
callbacks.PrivmsgCommandAndRegexp.die(self)
|
||||||
|
|
||||||
def makeDb(self, filename):
|
def makeDb(self, filename):
|
||||||
if os.path.exists(filename):
|
if os.path.exists(filename):
|
||||||
@ -192,6 +192,8 @@ class URL(callbacks.PrivmsgCommandAndRegexp,
|
|||||||
r"https?://[^\])>\s]+"
|
r"https?://[^\])>\s]+"
|
||||||
if not ircutils.isChannel(msg.args[0]):
|
if not ircutils.isChannel(msg.args[0]):
|
||||||
return
|
return
|
||||||
|
if callbacks.addressed(irc.nick, msg):
|
||||||
|
return
|
||||||
channel = msg.args[0]
|
channel = msg.args[0]
|
||||||
if self.registryValue('titleSnarfer', channel):
|
if self.registryValue('titleSnarfer', channel):
|
||||||
url = match.group(0)
|
url = match.group(0)
|
||||||
|
Loading…
Reference in New Issue
Block a user