1
0
Fork 0
mirror of https://github.com/immich-app/immich.git synced 2024-12-29 15:11:58 +00:00

chore(web): ensure goto is awaited for login page (#12087)

* chore(web): ensure goto is await for login page

* ensure server config is updated after onboarding is finished
This commit is contained in:
Alex 2024-08-27 17:29:50 -05:00 committed by GitHub
parent 028be6738e
commit be476d7982
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 5 additions and 3 deletions

View file

@ -17,9 +17,9 @@
</p>
<LoginForm
onSuccess={() => goto(AppRoute.PHOTOS, { invalidateAll: true })}
onFirstLogin={() => goto(AppRoute.AUTH_CHANGE_PASSWORD)}
onOnboarding={() => goto(AppRoute.AUTH_ONBOARDING)}
onSuccess={async () => await goto(AppRoute.PHOTOS, { invalidateAll: true })}
onFirstLogin={async () => await goto(AppRoute.AUTH_CHANGE_PASSWORD)}
onOnboarding={async () => await goto(AppRoute.AUTH_ONBOARDING)}
/>
</FullscreenContainer>
{/if}

View file

@ -6,6 +6,7 @@
import OnboadingStorageTemplate from '$lib/components/onboarding-page/onboarding-storage-template.svelte';
import OnboardingTheme from '$lib/components/onboarding-page/onboarding-theme.svelte';
import { AppRoute, QueryParameter } from '$lib/constants';
import { retrieveServerConfig } from '$lib/stores/server-config.store';
import { updateAdminOnboarding } from '@immich/sdk';
let index = 0;
@ -35,6 +36,7 @@
const handleDoneClicked = async () => {
if (index >= onboardingSteps.length - 1) {
await updateAdminOnboarding({ adminOnboardingUpdateDto: { isOnboarded: true } });
await retrieveServerConfig();
await goto(AppRoute.PHOTOS);
} else {
index++;