Revision: 5619
Author: rotem
Date: 2008-06-23 19:22:50 +0000 (Mon, 23 Jun 2008)
Log Message:
-----------
Several fixes.
Modified Paths:
--------------
trunk/pywikipedia/wikipedia.py
Modified: trunk/pywikipedia/wikipedia.py
===================================================================
--- trunk/pywikipedia/wikipedia.py 2008-06-23 17:30:13 UTC (rev 5618)
+++ trunk/pywikipedia/wikipedia.py 2008-06-23 19:22:50 UTC (rev 5619)
@@ -2163,7 +2163,7 @@
else:
response, data = self.site().postForm(address, predata, sysop = True)
if data:
- self.site().checkBlocks(sysop = sysop)
+ self.site().checkBlocks(sysop = True)
if self.site().mediawiki_message('actioncomplete') in data:
output(u'Page %s deleted' % self.aslink(forceInterwiki = True))
return True
@@ -2279,7 +2279,7 @@
self._getActionUser(action = 'undelete', sysop = True)
# Check blocks
- self.site().checkBlocks(sysop = sysop)
+ self.site().checkBlocks(sysop = True)
if throttle:
put_throttle()
@@ -2318,10 +2318,10 @@
"""
# Login
- sysop = self._getActionUser(action = 'protect', sysop = True)
+ self._getActionUser(action = 'protect', sysop = True)
# Check blocks
- self.site().checkBlocks(sysop = sysop)
+ self.site().checkBlocks(sysop = True)
address = self.site().protect_address(self.urlname())
if unprotect:
@@ -2396,7 +2396,7 @@
return True
else:
#Normally, we expect a 302 with no data, so this means an error
- self.site().checkBlocks(sysop = sysop)
+ self.site().checkBlocks(sysop = True)
output(u'Failed to change protection level of page %s:'
% self.aslink())
output(u"HTTP response code %s" % response.status)