From 437ab9165027732f70e0c0a6812fdf91f14d9d87 Mon Sep 17 00:00:00 2001 From: Claude Brisson Date: Thu, 29 Feb 2024 23:11:01 +0100 Subject: [PATCH] Bugfix --- view-webapp/src/main/webapp/js/api.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/view-webapp/src/main/webapp/js/api.js b/view-webapp/src/main/webapp/js/api.js index 5b0e08f..8582ba9 100644 --- a/view-webapp/src/main/webapp/js/api.js +++ b/view-webapp/src/main/webapp/js/api.js @@ -19,7 +19,7 @@ let headers = function(withJson) { if (withJson) { ret['Content-Type'] = 'application/json'; } - if (apiToken) { + if (typeof(apiToken) !== 'undefined') { ret['Authorization'] = `Bearer ${apiToken}`; } return ret;