From 5e746295bc5040d6f585bf77fc3658a26ef06af9 Mon Sep 17 00:00:00 2001 From: ddejongh Date: Thu, 11 Jun 2015 16:24:37 +0200 Subject: [PATCH] application constants --- js/app.js | 8 ++++---- js/constants/application_constants.js | 6 +++--- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/js/app.js b/js/app.js index 447ecc96..88809c50 100644 --- a/js/app.js +++ b/js/app.js @@ -15,15 +15,15 @@ let headers = { 'Content-Type': 'application/json' }; -if (window.DEBUG) { - headers.Authorization = 'Basic ' + window.CREDENTIALS; -} +//if (window.DEBUG) { +// headers.Authorization = 'Basic ' + window.CREDENTIALS; +//} fetch.defaults({ urlMap: ApiUrls, http: { headers: headers, - credentials: 'same-origin' + credentials: 'include' }, fatalErrorHandler: (err) => { console.log(err); diff --git a/js/constants/application_constants.js b/js/constants/application_constants.js index 508eebda..da7c8482 100644 --- a/js/constants/application_constants.js +++ b/js/constants/application_constants.js @@ -5,10 +5,10 @@ let constants = { //FIXME: referring to a global variable in `window` is not // super pro. What if we render stuff on the server? - //'baseUrl': window.BASE_URL, + 'baseUrl': window.BASE_URL, 'apiEndpoint': window.API_ENDPOINT, - 'baseUrl': 'http://staging.ascribe.io/api/', - 'debugCredentialBase64': 'ZGltaUBtYWlsaW5hdG9yLmNvbTowMDAwMDAwMDAw', // dimi@mailinator:0000000000 + //'baseUrl': 'http://staging.ascribe.io/api/', + //'debugCredentialBase64': 'ZGltaUBtYWlsaW5hdG9yLmNvbTowMDAwMDAwMDAw', // dimi@mailinator:0000000000 'aclList': ['edit', 'consign', 'consign_request', 'unconsign', 'unconsign_request', 'transfer', 'loan', 'loan_request', 'share', 'download', 'view', 'delete', 'del_from_collection', 'add_to_collection'] };