This is a bit simpler and has a marginal performance gain.
---
gitsrht/blueprints/repo.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/gitsrht/blueprints/repo.py b/gitsrht/blueprints/repo.py
index 90c8c8a..1bc86c2 100644
--- a/gitsrht/blueprints/repo.py
+++ b/gitsrht/blueprints/repo.py
@@ -103,7 +103,7 @@ def _highlight_file(repo, ref, entry, data, blob_id, commit_id):
def linecounter(count):
out = []
for i in range(1, count + 1):
- out.append('<a href="#L{}" id="L{}">{}\n</a>'.format(i, i, i))
+ out.append(f'<a href="#L{i}" id="L{i}">{i}\n</a>')
return "".join(out)
def render_empty_repo(owner, repo, view):
--
2.43.0