http://www.mediawiki.org/wiki/Special:Code/pywikipedia/11777
Revision: 11777 Author: legoktm Date: 2013-07-21 06:58:03 +0000 (Sun, 21 Jul 2013) Log Message: ----------- Fix editAliases function, patch by Pyfisch
Modified Paths: -------------- branches/rewrite/pywikibot/page.py
Modified: branches/rewrite/pywikibot/page.py =================================================================== --- branches/rewrite/pywikibot/page.py 2013-07-20 11:43:26 UTC (rev 11776) +++ branches/rewrite/pywikibot/page.py 2013-07-21 06:58:03 UTC (rev 11777) @@ -2262,7 +2262,6 @@ del self._link._title return Page(self).title(**kwargs)
- def __defined_by(self, singular=False): """ returns the parameters needed by the API to identify an item. @@ -2436,6 +2435,8 @@ value should be a list of strings. """ aliases = self.__normalizeLanguages(aliases) + for (key, strings) in aliases.items(): + aliases[key] = [{'language': key, 'value': i} for i in strings] data = {'aliases': aliases} self.editEntity(data, **kwargs)
pywikipedia-svn@lists.wikimedia.org