1
0
Fork 0

Fix numeration in node_to_plaintext

This commit is contained in:
Anna “CyberTailor” 2023-05-10 14:27:12 +05:00
parent a2e5f15c21
commit a8129d2a88
No known key found for this signature in database
GPG Key ID: E7B76EDC50864BB1
1 changed files with 1 additions and 1 deletions

View File

@ -267,7 +267,7 @@ def node_to_plaintext(el: PageElement) -> str:
if el.name == "ul"
else (
"%d. %s" % (i, li.replace("\n", "\n ").strip())
for i, li in enumerate(children)
for i, li in enumerate(children, 1)
),
)
return str.join("", map(node_to_plaintext, el.children))