more code fixes

This commit is contained in:
Dennis Eichhorn 2024-03-15 21:57:48 +00:00
parent 9a49bc34f1
commit 6aee640852
3 changed files with 3 additions and 3 deletions

View File

@ -71,7 +71,7 @@ final class ApiDriverAttributeController extends Controller
->with('type')
->where('type/id', $type->id)
->where('ref', (int) $request->getData('ref'))
->execute();
->executeCount();
if ($attr > 0) {
$response->header->status = RequestStatusCode::R_409;

View File

@ -71,7 +71,7 @@ final class ApiVehicleAttributeController extends Controller
->with('type')
->where('type/id', $type->id)
->where('ref', (int) $request->getData('ref'))
->execute();
->executeCount();
if ($attr > 0) {
$response->header->status = RequestStatusCode::R_409;

View File

@ -30,7 +30,7 @@ trait ApiControllerVehicleTrait
{
$vehicleType = VehicleTypeMapper::getAll()->execute();
$vehicleTypeCount = \count($vehicleType);
$fuelTypeCount = FuelTypeMapper::count()->execute();
$fuelTypeCount = FuelTypeMapper::count()->executeCount();
$response = new HttpResponse();
$request = new HttpRequest();