From 6277c3da0968d2a42249e5d1f3292cd5fc1acc8a Mon Sep 17 00:00:00 2001 From: Javier Segarra Date: Tue, 30 Apr 2024 11:26:12 +0200 Subject: [PATCH] fix(salix): refs #7272 #7272 Remove aclService from auth.js --- front/core/services/auth.js | 19 +++++++------------ 1 file changed, 7 insertions(+), 12 deletions(-) diff --git a/front/core/services/auth.js b/front/core/services/auth.js index fc8ba2d63..c3aa6a3c7 100644 --- a/front/core/services/auth.js +++ b/front/core/services/auth.js @@ -7,18 +7,15 @@ import UserError from 'core/lib/user-error'; * @property {Boolean} loggedIn Whether the user is currently logged */ export default class Auth { - constructor($http, $q, vnApp, $translate, $state, $transitions, $window, vnToken, vnModules, aclService) { + constructor($http, $q, $state, $transitions, $window, vnToken, vnModules) { Object.assign(this, { $http, $q, - vnApp, - $translate, $state, $transitions, $window, vnToken, vnModules, - aclService, loggedIn: false }); } @@ -111,13 +108,11 @@ export default class Auth { headers: {Authorization: json.data.token} }).then(({data}) => { this.vnToken.set(json.data.token, data.multimediaToken.id, now, json.data.ttl, remember); - this.loadAcls().then(() => { - let continueHash = this.$state.params.continue; - if (continueHash) - this.$window.location = continueHash; - else - this.$state.go('home'); - }); + let continueHash = this.$state.params.continue; + if (continueHash) + this.$window.location = continueHash; + else + this.$state.go('home'); }).catch(() => {}); } @@ -131,7 +126,7 @@ export default class Auth { this.vnToken.unset(); this.loggedIn = false; this.vnModules.reset(); - this.aclService.reset(); + this.vnModules.aclService.reset(); this.$state.go('login'); return promise;