Revision: 8193 Author: amir Date: 2010-05-18 01:34:52 +0000 (Tue, 18 May 2010)
Log Message: ----------- Some better but needs using Regex
Modified Paths: -------------- trunk/pywikipedia/featured.py
Modified: trunk/pywikipedia/featured.py =================================================================== --- trunk/pywikipedia/featured.py 2010-05-18 00:38:36 UTC (rev 8192) +++ trunk/pywikipedia/featured.py 2010-05-18 01:34:52 UTC (rev 8193) @@ -583,8 +583,9 @@ site = wikipedia.getSite() comment = wikipedia.setAction(wikipedia.translate(site, msg_former) % (fromsite.lang, a.title())) name=templatelist[0] + name2=name[0].lower()+name[1:] text=text.replace(u"{{%s|%s}}" %(name, fromsite.lang),'',1) - text=text.replace(u"{{%s|%s}}" %(name.lower(), fromsite.lang),'',1) + text=text.replace(u"{{%s|%s}}" %(name2, fromsite.lang),'',1) if not dry: try: atrans.put(text, comment)