Skip to content

Commit a8e5fe4

Browse files
committed
fix(catalog): tolerate missing product entitlements
1 parent a4b12b5 commit a8e5fe4

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

server/src/internal/catalog/actions/previewUpdateCatalog/previewUpdateCatalog.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ const productUsesFeature = ({
4242
product: FullProduct;
4343
featureId: string;
4444
}) =>
45-
product.entitlements.some(
45+
(product.entitlements ?? []).some(
4646
(entitlement) => entitlement.feature.id === featureId,
4747
) || product.prices.some((price) => price.config?.feature_id === featureId);
4848

0 commit comments

Comments
 (0)