From d5ea71b2892b84040b07107643d939f1cfb74d67 Mon Sep 17 00:00:00 2001 From: Bryan Newbold Date: Tue, 27 Jul 2021 17:00:32 -0700 Subject: refs: fix offset/limit bug --- python/fatcat_web/ref_routes.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'python/fatcat_web') diff --git a/python/fatcat_web/ref_routes.py b/python/fatcat_web/ref_routes.py index 72f115cf..6f887c4d 100644 --- a/python/fatcat_web/ref_routes.py +++ b/python/fatcat_web/ref_routes.py @@ -18,7 +18,7 @@ from fatcat_web.entity_helpers import * def _refs_web(direction, release_ident=None, work_ident=None, openlibrary_id=None) -> RefHits: offset = request.args.get('offset', '0') offset = max(0, int(offset)) if offset.isnumeric() else 0 - limit = request.args.get('offset', '30') + limit = request.args.get('limit', '30') limit = min(max(0, int(limit)), 100) if limit.isnumeric() else 30 if direction == "in": hits = get_inbound_refs( -- cgit v1.2.3