Removes getting the window location pathname, because it screws up the session redirect

This commit is contained in:
Aaron Louie 2020-05-22 15:28:15 -04:00
parent 0433e5f069
commit 2c96537554
2 changed files with 2 additions and 6 deletions

View File

@ -9,5 +9,5 @@ export const environment: AppEnvironment = {
production: _has(ENV, 'production', '$PRODUCTION') ? (ENV.production === 'true') : false, production: _has(ENV, 'production', '$PRODUCTION') ? (ENV.production === 'true') : false,
api: _has(ENV, 'api', '$API_URL') ? ENV.api : 'http://localhost:5000/v1.0', api: _has(ENV, 'api', '$API_URL') ? ENV.api : 'http://localhost:5000/v1.0',
irbUrl: _has(ENV, 'irbUrl', '$IRB_URL') ? ENV.irbUrl : 'http://localhost:5001', irbUrl: _has(ENV, 'irbUrl', '$IRB_URL') ? ENV.irbUrl : 'http://localhost:5001',
baseHref: _has(ENV, 'baseHref', '$BASE_HREF') ? ENV.baseHref : (window as any)._app_base || '/', baseHref: _has(ENV, 'baseHref', '$BASE_HREF') ? ENV.baseHref : '/',
}; };

View File

@ -3,12 +3,8 @@
<head> <head>
<meta charset="utf-8"> <meta charset="utf-8">
<title>CR Connect - Configuration</title> <title>CR Connect - Configuration</title>
<base href="$BASE_HREF"> <base href="/">
<script> <script>
(function() {
window['_app_base'] = '/' + window.location.pathname.split('/')[1];
})();
const ENV = { const ENV = {
homeRoute: '$HOME_ROUTE', homeRoute: '$HOME_ROUTE',
production: '$PRODUCTION', production: '$PRODUCTION',