Remove customer checking. #588

This commit is contained in:
Korina Cordero 2021-06-18 08:27:47 +00:00
parent ceb54afa10
commit 391237f08f

View file

@ -3278,16 +3278,10 @@ class APIController extends Controller implements LoggedController
// find the customer vehicle and get the vehicle // find the customer vehicle and get the vehicle
$cv = $em->getRepository(CustomerVehicle::class)->findOneBy(['plate_number' => $clean_plate, 'customer' => $customer]); $cv = $em->getRepository(CustomerVehicle::class)->findOneBy(['plate_number' => $clean_plate, 'customer' => $customer]);
if ($cv != null) if ($cv != null)
{
// confirm that customer vehicle found does belong to customer
if ($cv->getCustomer() == $customer)
{ {
$vehicle = $cv->getVehicle(); $vehicle = $cv->getVehicle();
return $vehicle; return $vehicle;
} }
else
return null;
}
} }
return null; return null;