Have sms search for message_id instead of id #394

This commit is contained in:
Kendrick Chan 2020-05-03 23:02:47 +08:00
parent 106a38499d
commit 0d50c864d6

View file

@ -27,7 +27,7 @@ class SMSController extends Controller
error_log(print_r($data, true));
// data has id?
if (!isset($data['id']))
if (!isset($data['message_id']))
{
error_log('SMSDR: no id sent');
$resp = new Response();
@ -48,7 +48,7 @@ class SMSController extends Controller
}
// find sms
$sms = $em->getRepository(SMSMessage::class)->find($data['id']);
$sms = $em->getRepository(SMSMessage::class)->find($data['message_id']);
if ($sms == null)
{
error_log('SMSDR: no sms found');