php-firebase-cloud-messaging icon indicating copy to clipboard operation
php-firebase-cloud-messaging copied to clipboard

loading client in controller throws and error

Open NohaElsherbiny opened this issue 9 years ago • 1 comments

loading client in controller throws an error on live server and don't send notifications, while it send notifications normally locally and on staging server. any clue?

here's the live server error: request.CRITICAL: Uncaught PHP Exception Symfony\Component\Debug\Exception\ClassNotFoundException: "Attempted to load class "Client" from namespace "sngrl\PhpFirebaseCloudMessaging". Did you forget a "use" statement for e.g. "Symfony\Component\HttpKernel\Client", "Symfony\Component\BrowserKit\Client", "Symfony\Bundle\FrameworkBundle\Client" or "GuzzleHttp\Client"?" at /var/www/ibus/src/AppBundle/Controller/DriverController.php line 207 {"exception":"[object](Symfony\Component\Debug\Exception\ClassNotFoundException%28code: 0%29: Attempted to load class "Client" from namespace "sngrl\PhpFirebaseCloudMessaging".nDid you forget a "use" statement for e.g. "Symfony\Component\HttpKernel\Client", "Symfony\Component\BrowserKit\Client", "Symfony\Bundle\FrameworkBundle\Client" or "GuzzleHttp\Client"? at /var/www/ibus/src/AppBundle/Controller/DriverController.php:207)"} []

NohaElsherbiny avatar Oct 17 '16 12:10 NohaElsherbiny

I have created a Symfony Bundle as a wrapper for this Library. Very easy to use. https://github.com/redjanym/FCMBundle

redjanym avatar Oct 21 '16 08:10 redjanym