Skip to content

Commit

Permalink
Merge pull request #157 from vtex-apps/bugfix/null-skuSpecifications
Browse files Browse the repository at this point in the history
setting skuSpecification to empty array if it's null
  • Loading branch information
wender authored Feb 27, 2023
2 parents 56e49f3 + 3edd1a8 commit 8c6fe28
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.

## [Unreleased]

### Fixed
- `skuSpecifications` to empty array if **null**

## [1.15.7] - 2023-02-24

### Fixed
Expand Down
1 change: 1 addition & 0 deletions react/utils/normalize.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ export function mapCatalogProductToProductSummary(
if (!product) return null
const normalizedProduct = {
...product,
skuSpecifications: product.skuSpecifications ?? [],
wishlistPage: true,
wishlistId,
}
Expand Down

0 comments on commit 8c6fe28

Please sign in to comment.