ui: Fix non admin logouts (#8065)

If a user (non-admin) logs out from a session, then login page is not loading completely. Few starter APIs like listIds are failing and showing unauthorised access notification in Login Page. Also if SAML is enabled, it is not getting enabled since the corresponding API are failed. User needs to refresh the browser to get it back.

(cherry picked from commit 8b281284a2)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
This commit is contained in:
Harikrishna 2023-10-11 16:58:29 +05:30 committed by Rohit Yadav
parent f570934482
commit 84fee7b896
1 changed files with 1 additions and 1 deletions

View File

@ -142,7 +142,7 @@ export default {
(newValue, oldValue) => {
if (newValue && newValue.id && (!oldValue || newValue.id !== oldValue.id)) {
this.fetchData()
} else if (store.getters.userInfo.roletype !== 'Admin') {
} else if (store.getters.userInfo.roletype !== 'Admin' && !store.getters.logoutFlag) {
this.fetchData()
}
}