diff options
author | vrvarma <vv8305@att.com> | 2020-02-14 09:41:35 -0500 |
---|---|---|
committer | vrvarma <vv8305@att.com> | 2020-02-14 09:41:45 -0500 |
commit | 2c755666759b18652f9b93a87d3b0d1c5f256fd7 (patch) | |
tree | a1e751bc4a842a0ee0a4418d97e6c68ad8301d7c /osdf/webapp/appcontroller.py | |
parent | 741893e4cd6589bb5f65fa9b51c1c86aff5b5c98 (diff) |
Fix sonarcloud coverage reports issue
Change-Id: Ieaf2aac8ed425bdf547f6893262a3285470519d4
Signed-off-by: vrvarma <vv8305@att.com>
Issue-ID: OPTFRA-698
Diffstat (limited to 'osdf/webapp/appcontroller.py')
-rw-r--r-- | osdf/webapp/appcontroller.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/osdf/webapp/appcontroller.py b/osdf/webapp/appcontroller.py index 9714fb5..e48e93f 100644 --- a/osdf/webapp/appcontroller.py +++ b/osdf/webapp/appcontroller.py @@ -35,6 +35,7 @@ error_body = { unauthorized_message = json.dumps(error_body) + @auth_basic.get_password def get_pw(username): end_point = request.url.split('/')[-1] @@ -42,6 +43,7 @@ def get_pw(username): return cfg_base.http_basic_auth_credentials[auth_group].get( username) if auth_group else None + @auth_basic.error_handler def auth_error(): response = Response(unauthorized_message, content_type='application/json; charset=utf-8') @@ -58,4 +60,3 @@ def verify_pw(username, password): else: pw = get_pw(username) return pw == password - return False
\ No newline at end of file |