mirror of
https://github.com/vercel/commerce.git
synced 2025-07-27 04:01:23 +00:00
Add configuration to show product options when there's one variant available
This commit is contained in:
@@ -61,10 +61,9 @@ export default function getProductOperation({
|
||||
const config = commerce.getConfig(userConfig)
|
||||
const { fetch: apiFetch } = config // TODO: Send config.locale to Spree.
|
||||
|
||||
const { data: spreeSuccessResponse } = await apiFetch<IProduct>(
|
||||
'__UNUSED__',
|
||||
{ variables }
|
||||
)
|
||||
const {
|
||||
data: { data: spreeSuccessResponse },
|
||||
} = await apiFetch<{ data: IProduct }>('__UNUSED__', { variables })
|
||||
|
||||
return {
|
||||
product: normalizeProduct(
|
||||
|
Reference in New Issue
Block a user