Hello,
I am using the PHP API to send push-notifications. Everything worked fine, however when I set the expiry parameter, I'm getting the following error:
Uncaught Error: Call to undefined function UrbanAirship\Push\expiry() in /home/u/public_html/panel.php Stack trace: #0 {main} thrown in /home/u/public_html/panel.php on line 41
I'll share a snippet of the code where the error occurs:
try {
$response = $airship->push()
->setAudience(P\all)
->setNotification(P\notification($content))
->setOptions(P\expiry(10800))
->setDeviceTypes(P\all)
->send();
} catch (AirshipException $e) {
print_r($e);
}
How do I resolve this error?
-Thanks
Comments
1 comment