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
I'm unable to load the Client using the Laravel facade. If I change the getFacadeAccessor() method to return 'Shopify\Client' instead of 'shopify', it works fine though. Isn't the facade supposed to return the Client instead of just 'shopify'?
The text was updated successfully, but these errors were encountered:
I'm not familiar with Laravel, but all of the examples showing how to write Laravel facades return a string from the getFacadeAccessor(), not the underlying object, which is instead somehow bound to the application. I can't say that the rest of the implementation is correct (there is some sort of binding of the real underlying object going on in https://github.com/ShopifyExtras/PHP-Shopify-API-Wrapper/blob/master/src/Laravel/ServiceProvider.php), but the getFacadeAccessor() part definitely seems correct.
Yes, it turned out I had overwritten my app/config/app.php file with the array of Service Providers, and the facade is working properly after I fixed it.
I would however add a line in the readme file for reminding people who use Laravel to include that service provider in their app.php file, since it's easy to forget it otherwise :)
I'm unable to load the Client using the Laravel facade. If I change the
getFacadeAccessor()
method to return'Shopify\Client'
instead of'shopify'
, it works fine though. Isn't the facade supposed to return the Client instead of just'shopify'
?The text was updated successfully, but these errors were encountered: