summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--indoteknik_api/controllers/controller.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/indoteknik_api/controllers/controller.py b/indoteknik_api/controllers/controller.py
index cb5e2363..9d0ff64e 100644
--- a/indoteknik_api/controllers/controller.py
+++ b/indoteknik_api/controllers/controller.py
@@ -22,7 +22,7 @@ class Controller(http.Controller):
request.session.authenticate(db, username, password)
return True
except:
- authorization = wsgienv['HTTP_AUTHORIZATION']
+ authorization = wsgienv['HTTP_AUTHORIZATION'] or None
token = request.env['ir.config_parameter'].sudo().get_param('rest_api_token') or ''
if authorization == token:
request.session.authenticate(config.get('db_name'), 'it@fixcomart.co.id', 'Fixcomart378')