Skip to content

Commit 58a84d0

Browse files
Narek MkhitaryanNarek Mkhitaryan
authored andcommitted
fix in http_client paginate function
1 parent 1b39762 commit 58a84d0

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/superannotate/lib/infrastructure/services/http_client.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,10 @@ def paginate(
169169
res_data=pydantic.parse_obj_as(List[item_type], total),
170170
)
171171
else:
172-
response = ServiceResponse(res_data=total)
172+
response = ServiceResponse(
173+
status=_response.status,
174+
res_data=total,
175+
)
173176
if not _response.ok:
174177
response.set_error(_response.error)
175178
response.status = _response.status

0 commit comments

Comments
 (0)