Update WikiExtractor.py

Fix bug where it fails with an exception when n="1" or n="A"
This commit is contained in:
Daniel 2017-11-08 14:28:36 +00:00 committed by GitHub
parent 2a5e6aebc0
commit 45e56d4e9e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -2603,6 +2603,8 @@ def compact(text):
bullet = '%d. ' % listCount[i - 1] if n == '#' else '- '
page.append('{0:{1}s}'.format(bullet, len(listLevel)) + line)
elif options.toHTML:
if n not in listItem:
n = '*'
page.append(listItem[n] % line)
elif len(listLevel):
if options.toHTML: