Skip to content
This repository was archived by the owner on Jun 15, 2018. It is now read-only.
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions simplemediawiki.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,13 +103,13 @@ def __init__(self, api_url, cookie_file=None, cookiejar=None,
self._api_url = api_url
self._http_user = http_user
self._http_password = http_password
if cookiejar:
if cookiejar is not None:
self._cj = cookiejar
elif cookie_file:
elif cookie_file is not None:
self._cj = cookielib.LWPCookieJar(cookie_file)
try:
self._cj.load()
except IOError:
except cookielib.LoadError:
self._cj.save()
self._cj.load()
else:
Expand Down