web/satellite: fix frozen status banners not showing
This change moves the call to fetch user's frozen status into the getUser store action. It fixes an issue where the froze status banners will not show. Change-Id: I1a1853d5a89502e294848ceb6a8566120ecd4c10
This commit is contained in:
parent
b502310fe5
commit
250704493d
@ -46,15 +46,12 @@ export const useUsersStore = defineStore('users', () => {
|
||||
const configStore = useConfigStore();
|
||||
|
||||
const user = await api.get();
|
||||
user.freezeStatus = await api.getFrozenStatus();
|
||||
user.projectLimit ||= configStore.state.config.defaultProjectLimit;
|
||||
|
||||
setUser(user);
|
||||
}
|
||||
|
||||
async function getFrozenStatus(): Promise<void> {
|
||||
state.user.freezeStatus = await api.getFrozenStatus();
|
||||
}
|
||||
|
||||
async function disableUserMFA(request: DisableMFARequest): Promise<void> {
|
||||
await api.disableUserMFA(request.passcode, request.recoveryCode);
|
||||
}
|
||||
@ -112,7 +109,6 @@ export const useUsersStore = defineStore('users', () => {
|
||||
generateUserMFARecoveryCodes,
|
||||
clear,
|
||||
login,
|
||||
getFrozenStatus,
|
||||
setUser,
|
||||
updateSettings,
|
||||
getSettings,
|
||||
|
@ -728,7 +728,6 @@ onMounted(async () => {
|
||||
try {
|
||||
await Promise.all([
|
||||
usersStore.getUser(),
|
||||
usersStore.getFrozenStatus(),
|
||||
abTestingStore.fetchValues(),
|
||||
usersStore.getSettings(),
|
||||
]);
|
||||
|
@ -615,7 +615,6 @@ onMounted(async () => {
|
||||
try {
|
||||
await Promise.all([
|
||||
usersStore.getUser(),
|
||||
usersStore.getFrozenStatus(),
|
||||
abTestingStore.fetchValues(),
|
||||
usersStore.getSettings(),
|
||||
]);
|
||||
|
Loading…
Reference in New Issue
Block a user