Skip to content

Commit a951ac6

Browse files
authored
UI: Don't set management server ID if cookie isn't set (#13404)
1 parent 4262c02 commit a951ac6

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

ui/src/permission.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,10 @@ router.beforeEach((to, from, next) => {
9393
return
9494
}
9595
store.commit('SET_LOGIN_FLAG', true)
96-
store.commit('SET_MS_ID', Cookies.get('managementserverid'))
96+
const MS_ID = Cookies.get('managementserverid')
97+
if (MS_ID) {
98+
store.commit('SET_MS_ID', MS_ID)
99+
}
97100
}
98101
if (Object.keys(store.getters.apis).length === 0) {
99102
const cachedApis = vueProps.$localStorage.get(APIS, {})

0 commit comments

Comments
 (0)