http://www.mediawiki.org/wiki/Special:Code/pywikipedia/11258
Revision: 11258 Author: legoktm Date: 2013-03-25 07:17:53 +0000 (Mon, 25 Mar 2013) Log Message: ----------- Simplify logic, None > 0 is always false
Modified Paths: -------------- branches/rewrite/pywikibot/data/api.py
Modified: branches/rewrite/pywikibot/data/api.py =================================================================== --- branches/rewrite/pywikibot/data/api.py 2013-03-25 07:16:29 UTC (rev 11257) +++ branches/rewrite/pywikibot/data/api.py 2013-03-25 07:17:53 UTC (rev 11258) @@ -693,8 +693,7 @@ for item in resultdata: yield self.result(item) count += 1 - if self.limit is not None and self.limit > 0 \ - and count >= self.limit: + if self.limit > 0 and count >= self.limit: return if not "query-continue" in self.data: return