From 274381deaa03793b3aadf3107e19abaf5d734efc Mon Sep 17 00:00:00 2001 From: Daniel Dietzler <36593685+danieldietzler@users.noreply.github.com> Date: Thu, 17 Oct 2024 20:23:51 +0200 Subject: [PATCH] fix: person update state inconsistencies (#13556) --- .../[personId]/[[photos=photos]]/[[assetId=id]]/+page.svelte | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/web/src/routes/(user)/people/[personId]/[[photos=photos]]/[[assetId=id]]/+page.svelte b/web/src/routes/(user)/people/[personId]/[[photos=photos]]/[[assetId=id]]/+page.svelte index 037feaf35f..d68367d106 100644 --- a/web/src/routes/(user)/people/[personId]/[[photos=photos]]/[[assetId=id]]/+page.svelte +++ b/web/src/routes/(user)/people/[personId]/[[photos=photos]]/[[assetId=id]]/+page.svelte @@ -201,7 +201,7 @@ return; } try { - await updatePerson({ id: person.id, personUpdateDto: { featureFaceAssetId: asset.id } }); + person = await updatePerson({ id: person.id, personUpdateDto: { featureFaceAssetId: asset.id } }); notificationController.show({ message: $t('feature_photo_updated'), type: NotificationType.Info }); } catch (error) { handleError(error, $t('errors.unable_to_set_feature_photo')); @@ -252,7 +252,7 @@ try { isEditingName = false; - await updatePerson({ id: person.id, personUpdateDto: { name: personName } }); + person = await updatePerson({ id: person.id, personUpdateDto: { name: personName } }); notificationController.show({ message: $t('change_name_successfully'),