Revision: 5264 Author: nicdumz Date: 2008-04-23 15:48:15 +0000 (Wed, 23 Apr 2008)
Log Message: ----------- Use api_address instead of hard-coded /w/api.php
Modified Paths: -------------- trunk/pywikipedia/wikipedia.py
Modified: trunk/pywikipedia/wikipedia.py =================================================================== --- trunk/pywikipedia/wikipedia.py 2008-04-23 15:00:55 UTC (rev 5263) +++ trunk/pywikipedia/wikipedia.py 2008-04-23 15:48:15 UTC (rev 5264) @@ -1139,7 +1139,8 @@ ('autoconfirmed' or 'sysop') * expiry is the expiration time of the restriction """ - api_url = '/w/api.php?action=query&prop=info&inprop=protection&format=xml&titles=%s' % self.urlname() + api_url = self.site().api_address() + api_url += 'action=query&prop=info&inprop=protection&format=xml&titles=%s' % self.urlname() text = self.site().getUrl(api_url) if 'missing=""' in text: self._getexception = NoPage
pywikipedia-l@lists.wikimedia.org