Skip to content

Commit 9ccfde9

Browse files
committed
fix: query tweaks
1 parent a3e845e commit 9ccfde9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/index.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ async function fetchProductCore(opt, config) {
8080

8181
const json = await resp.json();
8282
try {
83-
const [product] = json.data.products;
83+
const [product] = json.data.products.items;
8484
if (!product) {
8585
throw errorWithResponse(404, 'could not find product', json.errors);
8686
}
@@ -113,7 +113,7 @@ async function lookupProductSKU(urlkey, config) {
113113

114114
const json = await resp.json();
115115
try {
116-
const [product] = json.data.products;
116+
const [product] = json.data.products.items;
117117
if (!product) {
118118
throw errorWithResponse(404, 'could not find product sku', json.errors);
119119
}

0 commit comments

Comments
 (0)