fallback for searchCar if info couldn't be found

This commit is contained in:
Jim Shield committed 2026-11-05 17:39:26 +00:00
1 parent a96602d351
commit 8c947aae73
1 file changed
+3
+3
View File
@@ -80,6 +80,9 @@ function searchCar(vehicle)
carInfo.price = 0
carInfo.class = classlist[GetVehicleClass(vehicle) + 1], GetVehicleClass(vehicle)
end
-- without this the function returned nil and anything doing
-- searchCar(vehicle).class would throw
return carInfo
end
else
return carInfo