Revision: 6695 Author: nicdumz Date: 2009-04-24 06:46:34 +0000 (Fri, 24 Apr 2009)
Log Message: ----------- PageTree bugfix: use iteritems()
Modified Paths: -------------- trunk/pywikipedia/interwiki.py
Modified: trunk/pywikipedia/interwiki.py =================================================================== --- trunk/pywikipedia/interwiki.py 2009-04-24 06:38:24 UTC (rev 6694) +++ trunk/pywikipedia/interwiki.py 2009-04-24 06:46:34 UTC (rev 6695) @@ -545,11 +545,11 @@ """ Yields (Site, number of pages in site) pairs """ - for site, d in self.tree: + for site, d in self.tree.iteritems(): yield site, len(d)
def __iter__(self): - for site, d in self.tree: + for site, d in self.tree.iteritems(): for page in d: yield page
pywikipedia-svn@lists.wikimedia.org