fix checkout url, product w/ no images error

This commit is contained in:
Greg Hoskin
2021-05-12 11:23:04 -05:00
parent 9675be1546
commit e7d0f56e85
2 changed files with 2 additions and 2 deletions

View File

@@ -60,7 +60,7 @@ const normalizeProductOption = ({
}
const normalizeProductImages = (images: SwellImage[]) => {
if (!images) {
if (!images || images.length < 1) {
return [{ url: '/' }]
}
return images?.map(({ file, ...rest }: SwellImage) => ({