From 56d92f3e66a7d4ebcf124b53220a84c841e55b02 Mon Sep 17 00:00:00 2001 From: Saketh Varma Date: Thu, 20 Mar 2025 23:50:14 -0300 Subject: [PATCH] fix(ui): versions null reference issues (#12919) --- .../profile/schema/components/StructuredPropValues.tsx | 4 ++-- .../profile/schema/components/StructuredPropValues.tsx | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/datahub-web-react/src/app/entity/dataset/profile/schema/components/StructuredPropValues.tsx b/datahub-web-react/src/app/entity/dataset/profile/schema/components/StructuredPropValues.tsx index 91379ce97f..81c737d42b 100644 --- a/datahub-web-react/src/app/entity/dataset/profile/schema/components/StructuredPropValues.tsx +++ b/datahub-web-react/src/app/entity/dataset/profile/schema/components/StructuredPropValues.tsx @@ -16,14 +16,14 @@ const MoreIndicator = styled.span` `; interface Props { - schemaFieldEntity: SchemaFieldEntity; + schemaFieldEntity: SchemaFieldEntity | undefined; propColumn: SearchResult | undefined; } const StructuredPropValues = ({ schemaFieldEntity, propColumn }: Props) => { const entityRegistry = useEntityRegistry(); - const property = schemaFieldEntity.structuredProperties?.properties?.find( + const property = schemaFieldEntity?.structuredProperties?.properties?.find( (prop) => prop.structuredProperty.urn === propColumn?.entity?.urn, ); const propRow = property ? mapStructuredPropertyToPropertyRow(property) : undefined; diff --git a/datahub-web-react/src/app/entityV2/dataset/profile/schema/components/StructuredPropValues.tsx b/datahub-web-react/src/app/entityV2/dataset/profile/schema/components/StructuredPropValues.tsx index 33c8618d81..2eba542ae4 100644 --- a/datahub-web-react/src/app/entityV2/dataset/profile/schema/components/StructuredPropValues.tsx +++ b/datahub-web-react/src/app/entityV2/dataset/profile/schema/components/StructuredPropValues.tsx @@ -16,14 +16,14 @@ const MoreIndicator = styled.span` `; interface Props { - schemaFieldEntity: SchemaFieldEntity; + schemaFieldEntity: SchemaFieldEntity | undefined; propColumn: SearchResult | undefined; } const StructuredPropValues = ({ schemaFieldEntity, propColumn }: Props) => { const entityRegistry = useEntityRegistry(); - const property = schemaFieldEntity.structuredProperties?.properties?.find( + const property = schemaFieldEntity?.structuredProperties?.properties?.find( (prop) => prop.structuredProperty.urn === propColumn?.entity?.urn, ); const propRow = property ? mapStructuredPropertyToPropertyRow(property) : undefined;