From 2746670ff3c7e24c074d5f400874a9d306e2e48b Mon Sep 17 00:00:00 2001 From: Charles Bochet Date: Fri, 29 Nov 2024 15:29:13 +0100 Subject: [PATCH] Fix activity target picker --- .../components/ActivityTargetInlineCellEditMode.tsx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/packages/twenty-front/src/modules/activities/inline-cell/components/ActivityTargetInlineCellEditMode.tsx b/packages/twenty-front/src/modules/activities/inline-cell/components/ActivityTargetInlineCellEditMode.tsx index 7719f4576bed..d3efdcb5465f 100644 --- a/packages/twenty-front/src/modules/activities/inline-cell/components/ActivityTargetInlineCellEditMode.tsx +++ b/packages/twenty-front/src/modules/activities/inline-cell/components/ActivityTargetInlineCellEditMode.tsx @@ -98,7 +98,7 @@ export const ActivityTargetInlineCellEditMode = ({ async () => { const activityTargetsAfterUpdate = activityTargetWithTargetRecords.filter((activityTarget) => { - const record = snapshot + const recordSelectedInMultiSelect = snapshot .getLoadable( objectRecordMultiSelectComponentFamilyState({ scopeId: relationPickerScopeId, @@ -107,7 +107,9 @@ export const ActivityTargetInlineCellEditMode = ({ ) .getValue() as ObjectRecordAndSelected; - return record.selected; + return recordSelectedInMultiSelect + ? recordSelectedInMultiSelect.selected + : true; }); setActivityFromStore((currentActivity) => { if (isNull(currentActivity)) {