1
0
Fork 0
forked from github/pelican

File fixes for ruff B007, RUF015, PLR1722

This commit is contained in:
boxydog 2024-05-31 08:48:44 -05:00
commit 9b77a9027b
5 changed files with 48 additions and 51 deletions

View file

@ -483,7 +483,7 @@ class _HTMLWordTruncator(HTMLParser):
def getoffset(self) -> int:
line_start = 0
lineno, line_offset = self.getpos()
for i in range(lineno - 1):
for _ in range(lineno - 1):
line_start = self.rawdata.index("\n", line_start) + 1
return line_start + line_offset