Seeing 'Can't find variable: getProductDefaults' error thrown after a call to the Storefront API

Highlighted
New Member
3 0 0

Hi,

 

So we've seeing seeing this `Can't find variable: getProductDefaults` error popping up in our error logs and they all seem to happen after a call to the Storefront API.

We are using the JS Buy SDK along with making graph QL calls using the unoptimized bundle. Seems to only happen on mobile (mostly Mobile Safari but some on Android Chrome) but it's been hard to reproduce this issue locally. Since these errors pop up after a Storefront API call and given the name of the missing variable, we're guessing it's something with the Storefront API.

Can anyone verify that this `getProductDefaults` is in fact present in the Storefront API code or JS Buy SDK?

 

Ted

0 Likes
Highlighted
Shopify Staff
Shopify Staff
491 97 88

Hey Ted, 

 

It sounds plausible although I don't immediately recognize getProductDefaults as being part of the SDK / Storefront API. Do you have a request ID from a response header where I can look into the logs closer to see what could be happening? 

Vix | Developer Support @ Shopify
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Click Accept as Solution 


0 Likes