import express from 'express';

export async function VehicleIsSpawned(req: express.Request, res: express.Response): Promise<express.Response<any, Record<string, any>>> {
    const vehicle = mp.vehicles.toArray().find((v) => v.vehicleEntity?.id === Number(req.params.vehicleId));

    return res.json({
        spawned: !!vehicle,
    });
}
