Skip to content
Snippets Groups Projects
Commit ec4a6d2a authored by Daniel Nemergut's avatar Daniel Nemergut
Browse files

Making capability required in the get versions request

parent e38ebe2c
No related branches found
No related tags found
3 merge requests!1706merge 2.8.4 to main,!1696Catch 2.8.5-DEVELOPMENT up with the latest 2.8.4,!1695CASA matrix testing fixes
......@@ -72,9 +72,13 @@ def get_casa_versions(request: Request) -> Response:
or a 404 response (HTTPNotFound) if none are returned
"""
body = parse_body(request)
if "capability" not in body:
return HTTPBadRequest(detail=f"Capability not given")
params = {
"version": body["version"] if "version" in body else None,
"capability": body["capability"] if "capability" in body else None,
"capability": body["capability"],
"telescope": body["telescope"] if "telescope" in body else None,
}
params = {k: v for k, v in params.items() if v is not None}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment