From 1a09393dcb425250fc92c73b3584884f4f96e6c8 Mon Sep 17 00:00:00 2001 From: Tom Hacohen Date: Mon, 28 Dec 2020 10:29:47 +0200 Subject: [PATCH] Also add 401 to permission responses. --- etebase_fastapi/utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/etebase_fastapi/utils.py b/etebase_fastapi/utils.py index 487f03a..2ee3700 100644 --- a/etebase_fastapi/utils.py +++ b/etebase_fastapi/utils.py @@ -44,4 +44,4 @@ def is_collection_admin(collection, user): response_model_dict = {"model": HttpErrorOut} -permission_responses = {403: response_model_dict} +permission_responses = {401: response_model_dict, 403: response_model_dict}