fix: solve a case where fields stays empty in EditIdentity

This commit is contained in:
Massedil
2025-06-29 15:56:51 +02:00
parent 5a65d3d549
commit 57c2f9718e

View File

@@ -285,12 +285,17 @@ const baseIdentity: IPerson = {
const identity = ref<IPerson>(baseIdentity);
watch(person, () => {
console.debug("person changed", person.value);
if (person.value) {
identity.value = { ...person.value };
}
});
watch(
person,
() => {
console.debug("person changed", person.value);
if (person.value) {
identity.value = { ...person.value };
}
},
// We need to call "immediate: true" because when first loading update/xxx, there is no change to person
{ immediate: true }
);
const avatarMaxSize = useAvatarMaxSize();