Skip to content

Commit

Permalink
Fix section handling in constructor
Browse files Browse the repository at this point in the history
  • Loading branch information
alexz-enwp committed Jun 5, 2015
1 parent 7f07afc commit c6527b8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions wikitools/page.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ def namespaceDetect(title, site):
class Page(object):
""" A page on the wiki"""

def __init__(self, site, title=False, check=True, followRedir=True, section=False, sectionnumber=False, pageid=False, namespace=False):
def __init__(self, site, title=False, check=True, followRedir=True, section=False, sectionnumber=None, pageid=False, namespace=False):
"""
wiki - A wiki object
title - The page title, as a string or unicode object
Expand Down Expand Up @@ -117,7 +117,7 @@ def __init__(self, site, title=False, check=True, followRedir=True, section=Fals
else:
self.unprefixedtitle = self.title

if section or sectionnumber is not False:
if section or sectionnumber is not None:
self.setSection(section, sectionnumber)
else:
self.section = False
Expand Down

0 comments on commit c6527b8

Please sign in to comment.