Skip to content

Commit

Permalink
Fix new mypy errors
Browse files Browse the repository at this point in the history
  • Loading branch information
sam-leonard-ct committed Jan 13, 2025
1 parent 85b8563 commit db7be77
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
3 changes: 1 addition & 2 deletions doorstop/core/document.py
Original file line number Diff line number Diff line change
Expand Up @@ -880,8 +880,7 @@ def get_issues(
@staticmethod
def _get_issues_level(items):
"""Yield all the document's issues related to item level."""
prev = items[0] if items else None
for item in items[1:]:
for prev, item in zip(items, items[1:]):
puid = prev.uid
plev = prev.level
nuid = item.uid
Expand Down
3 changes: 2 additions & 1 deletion doorstop/core/publishers/html.py
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,8 @@ def lines_index(self, filenames, tree=None):
text = tree.draw(html_links=True) if tree else None
yield ""
yield "<h3>Tree Structure:</h3>"
yield "<pre><code>" + text + "</pre></code>"
if text is not None:
yield "<pre><code>" + text + "</pre></code>"
yield ""
yield "<hr>"
# Additional files
Expand Down

0 comments on commit db7be77

Please sign in to comment.