From: Ian Jackson Date: Thu, 25 Oct 2018 16:26:14 +0000 (+0100) Subject: url observations: Rename `urlcomplaints' variable to `urlinfos' X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~matthewv/git?p=irc.git;a=commitdiff_plain;h=06c0c07d447720274294e901927625dc8e2d0b7b url observations: Rename `urlcomplaints' variable to `urlinfos' These are no longer complaints. Signed-off-by: Ian Jackson Conflicts: commands.py --- diff --git a/commands.py b/commands.py index cdc776c..6f5a4fb 100755 --- a/commands.py +++ b/commands.py @@ -401,18 +401,18 @@ class UrlLog: def firstmen(self): return nicetime(time.time()-self.first) def urltype(self): - z=min(len(urlcomplaints)-1, self.count-1) - return urlcomplaints[z] + z=min(len(urlinfos)-1, self.count-1) + return urlinfos[z] #(?:) is a regexp that doesn't group urlre = re.compile(r"((?:(?:http)|(?:nsfw))s?://[^ ]+)( |$)") hturlre= re.compile(r"(http)(s?://[^ ]+)( |$)") #matches \bre\:?\s+ before a regexp; (?i)==case insensitive match shibboleth = re.compile(r"(?i)\bre\:?\s+((?:(?:http)|(?:nsfw))s?://[^ ]+)( |$)") -urlcomplaints = ["a new", - "a fascinating", - "an interesting", - "a popular"] +urlinfos = ["a new", + "a fascinating", + "an interesting", + "a popular"] ### Deal with /msg bot url or ~url in channel def urlq(bot, cmd, nick, conn, public,urldb):