mirror of
https://github.com/vercel/commerce.git
synced 2025-07-24 10:41:23 +00:00
Fix add to cart & prepare for user activation
This commit is contained in:
@@ -14,6 +14,10 @@ export function getVariant(product: Product, opts: SelectedOptions) {
|
||||
option.displayName.toLowerCase() === key.toLowerCase()
|
||||
) {
|
||||
return option.values.find((v) => v.label.toLowerCase() === value)
|
||||
} else if (!value) {
|
||||
return !variant.options.filter(
|
||||
({ displayName }) => displayName.toLowerCase() === key
|
||||
).length
|
||||
}
|
||||
})
|
||||
)
|
||||
|
Reference in New Issue
Block a user