edamov / pushok

PHP client for Apple Push Notification Service (APNs) - Send push notifications to iOS using the new APNs HTTP/2 protocol with token-based (JWT with p8 private key)
MIT License
369 stars 119 forks source link

On success response there is no body. #41

Closed vbartusevicius closed 5 years ago

vbartusevicius commented 5 years ago

This fixes: Fatal Error (E_ERROR): Uncaught Symfony\Component\Debug\Exception\FatalThrowableError: Type error: Argument 3 passed to Pushok\Response::__construct() must be of the type string, null given, called in edamov/pushok/src/Client.php on line 124 in edamov/pushok/src/Response.php:144

https://developer.apple.com/library/archive/documentation/NetworkingInternet/Conceptual/RemoteNotificationsPG/CommunicatingwithAPNs.html

For a successful request, the body of the response is empty.