You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Catch this in my Sentry logs, sometimes Shopify seems to return null.
Maybe can we add something to catch the null in $this->jsonDecode($body);
Symfony\Component\Debug\Exception\FatalThrowableError: Return value of Osiset\BasicShopifyAPI::jsonDecode() must be an instance of stdClass, null returned
#19 /vendor/osiset/basic-shopify-api/src/Osiset/BasicShopifyAPI.php(1004): Osiset\BasicShopifyAPI::jsonDecode
#18 /vendor/osiset/basic-shopify-api/src/Osiset/BasicShopifyAPI.php(832): Osiset\BasicShopifyAPI::Osiset\{closure}
#17 /vendor/osiset/basic-shopify-api/src/Osiset/BasicShopifyAPI.php(868): Osiset\BasicShopifyAPI::rest
The text was updated successfully, but these errors were encountered:
@ianfortier Which osiset/basic-shopify-api version are you on? Check with composer info.
I recently released a new version last week and it doesn't have a type return because it could be stdClass or array now, previously it was just stdClass.
@khiconit It was changed because there was several people using this package with my other repository (laravel-shopify) and trying to map the responses to a Laravel JSON Resource, this is not possible with a stdClass.
The main return of rest/graph will return an array now instead of stdClass. However, the "body" of the response can be accessed as an array or stdClass.
Catch this in my Sentry logs, sometimes Shopify seems to return null.
Maybe can we add something to catch the null in
$this->jsonDecode($body);
The text was updated successfully, but these errors were encountered: