Skip to content

Commit

Permalink
Update routes.py
Browse files Browse the repository at this point in the history
  • Loading branch information
ahosgood authored Jan 10, 2024
1 parent c5e4c72 commit da788b1
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions app/search/routes.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,8 @@ def catalogue():
page = int(request.args["page"]) if "page" in request.args else 1
records_api = RecordsAPI()
records_api.query(query)
records_api.add_parameter("page", page)
try:
results = records_api.get_results()
results = records_api.get_results(page)
except ConnectionError:
return render_template("errors/api.html"), 502
except Exception:
Expand Down Expand Up @@ -83,9 +82,8 @@ def website():
articles_api.add_parameter("type", ",".join(types))
if "order" in request.args:
articles_api.add_parameter("order", request.args["order"])
articles_api.add_parameter("page", page)
try:
results = articles_api.get_results()
results = articles_api.get_results(page)
except ConnectionError:
return render_template("errors/api.html"), 502
except Exception:
Expand Down

0 comments on commit da788b1

Please sign in to comment.