https://sonarly.com/issue/18698?type=bug
When a view filter references a field metadata ID that no longer exists in the workspace's metadata, `getRecordFilterFieldMetadataItem` throws an unhandled error during React render, crashing the entire `/objects/people` page.
Fix: Changed `getRecordFilterFieldMetadataItem` from throwing when a field metadata ID is not found to returning `undefined`. Added an explicit `FieldMetadataItem | undefined` return type annotation.
Updated both callers (`isRecordFilterAboutSoftDelete` and `isSeeDeletedRecordsFilter` in `useCheckIsSoftDeleteFilter`) to handle the `undefined` case by returning `false` — meaning filters that reference deleted/missing field metadata are simply treated as non-soft-delete filters rather than crashing the page.
This also fixes the `hasAnySoftDeleteFilterOnViewComponentSelector` Jotai selector, which calls `isRecordFilterAboutSoftDelete` and was also crashing (visible in the breadcrumbs via `useSetAdvancedFilterDropdownAllRowsStates`).
Added a test for `getRecordFilterFieldMetadataItem` covering the found, not-found, and empty metadata cases.
The fix uses `isDefined` from `twenty-shared/utils` which is the team's standard null-check utility, already used throughout the codebase.