summaryrefslogtreecommitdiffstats
path: root/ecomp-portal-FE-os/client/src/app.js
diff options
context:
space:
mode:
authorhb123f <hbindu@research.att.com>2019-03-20 12:20:44 -0400
committerhb123f <hbindu@research.att.com>2019-03-20 14:13:55 -0400
commita70761c096192e38800bf38d6c7f61f52bf72007 (patch)
treecdc5264cec030bc7e677ff1d74c939c56ee51d0d /ecomp-portal-FE-os/client/src/app.js
parent3992004ee5f2b0b1635e2aef19c375db87079b52 (diff)
CADI AAF Integration and merging the code
Issue-ID: PORTAL-319 CADI AAF Integration and code merge Change-Id: I6e44f3b2741858d8d403b77a49ec9a0153084801 Signed-off-by: hb123f <hbindu@research.att.com>
Diffstat (limited to 'ecomp-portal-FE-os/client/src/app.js')
-rw-r--r--ecomp-portal-FE-os/client/src/app.js7
1 files changed, 4 insertions, 3 deletions
diff --git a/ecomp-portal-FE-os/client/src/app.js b/ecomp-portal-FE-os/client/src/app.js
index a481d867..ec531846 100644
--- a/ecomp-portal-FE-os/client/src/app.js
+++ b/ecomp-portal-FE-os/client/src/app.js
@@ -55,7 +55,7 @@ var app = angular.module('ecompApp', [
'oc.lazyLoad',
'b2b.att'
])
- .config(($stateProvider, $urlRouterProvider, $locationProvider, $httpProvider, ngDialogProvider, $controllerProvider, hammerDefaultOptsProvider) => {
+ .config(($stateProvider, $urlRouterProvider, $locationProvider, $httpProvider, ngDialogProvider, $controllerProvider, hammerDefaultOptsProvider, $sanitizeProvider) => {
app.controllerProvider = $controllerProvider;
$urlRouterProvider.otherwise('/error404');
$locationProvider.html5Mode(true);
@@ -102,13 +102,14 @@ var app = angular.module('ecompApp', [
'responseError': function (rejection) {
$log.error('Interceptor rejection: ' + JSON.stringify(rejection));
var $state = $injector.get('$state');
+ var $sanitize = $injector.get('$sanitize');
switch (rejection.status) {
case 401:
var globalLoginUrl = rejection.headers()['global-login-url'];
if (globalLoginUrl) {
- window.location = globalLoginUrl +
+ window.location = $sanitize(globalLoginUrl +
(globalLoginUrl.indexOf('?') === -1 ? '?' : '') +
- '&retUrl=' + encodeURI(window.location);
+ '&retUrl=' + encodeURI(window.location));
return;
}
break;