housekeeping: a null page is an empty one (Gitea answers no reactions with null)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017K4vyY3yUD3GsvoZaAtKkD
This commit is contained in:
1 parent
2efe67c9a9
commit
8645bdfb4d
1 file changed
+1
-1
@@ -46,7 +46,7 @@ def paged(path: str, pages: int = 40) -> list[dict]:
|
||||
sep = "&" if "?" in path else "?"
|
||||
out: list[dict] = []
|
||||
for page in range(1, pages + 1):
|
||||
batch = tm.gh("GET", f"{path}{sep}limit=50&page={page}")
|
||||
batch = tm.gh("GET", f"{path}{sep}limit=50&page={page}") or [] # Gitea answers an issue with no reactions with null
|
||||
out += batch
|
||||
if len(batch) < 50:
|
||||
break
|
||||
|
||||
Reference in new issue
Block a user