Revision: 5762 Author: filnik Date: 2008-07-26 09:46:04 +0000 (Sat, 26 Jul 2008)
Log Message: ----------- fixing whitetemplates detection
Modified Paths: -------------- trunk/pywikipedia/checkimages.py
Modified: trunk/pywikipedia/checkimages.py =================================================================== --- trunk/pywikipedia/checkimages.py 2008-07-26 08:36:01 UTC (rev 5761) +++ trunk/pywikipedia/checkimages.py 2008-07-26 09:46:04 UTC (rev 5762) @@ -1234,7 +1234,7 @@ white_template_found = 0 for l in hiddentemplate: if tagged == False: - res = re.findall(r'{{(?:[Tt]emplate:|)%s(?: \n|||\n|})' % l.lower(), g.lower()) + res = re.findall(r'{{(?:[Tt]emplate:|)%s[ \n]*?(?:\n|||})' % l.lower(), g.lower()) if res != []: white_template_found += 1 if l != '' and l != ' ': # Check that l is not nothing or a space
pywikipedia-l@lists.wikimedia.org