Change return response for locationSupport. #632

This commit is contained in:
Korina Cordero 2021-11-03 06:27:36 +00:00
parent acf5d964cf
commit 4ce09e9671

View file

@ -2288,6 +2288,13 @@ class APIController extends Controller implements LoggedController
]; ];
$res->setData($data); $res->setData($data);
// check if is_covered is false. If so, we need to set the error part in the response
if (!$is_covered)
{
$res->setError(true)
->setErrorMessage('Oops! Our service is limited to some areas in Metro Manila, Laguna, and Baguio only. We will update you as soon as we are able to cover your area');
}
return $res->getReturnResponse(); return $res->getReturnResponse();
} }