From 69fd4dc0b95e99c81b9d800659cb690ea6731405 Mon Sep 17 00:00:00 2001 From: zsloan Date: Mon, 3 Mar 2025 21:13:03 +0000 Subject: Simplify line where it was unnecessarily checking request.json twice --- gn_auth/auth/authorisation/data/views.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gn_auth/auth/authorisation/data/views.py') diff --git a/gn_auth/auth/authorisation/data/views.py b/gn_auth/auth/authorisation/data/views.py index 38eaad6..6d66788 100644 --- a/gn_auth/auth/authorisation/data/views.py +++ b/gn_auth/auth/authorisation/data/views.py @@ -189,7 +189,7 @@ def __search_mrna__(): def __request_key__(key: str, default: Any = ""): if bool(request_json()): return request_json().get(#type: ignore[union-attr] - key, request.args.get(key, request_json().get(key, default))) + key, request.args.get(key, default)) return request.args.get(key, request_json().get(key, default)) def __request_key_list__(key: str, default: tuple[Any, ...] = tuple()): -- cgit v1.2.3