Open solareon opened 7 months ago
Inserting a vehicle doesn't check for duplicate plates
Insert a vehicle with the same plate as an existing vehicle
Return an error to the calling resource
SQL error and potentially hang resource depending on how the export was called.
https://github.com/Qbox-project/qbx_vehicles/blob/0198d9dee99f3cf0ff174a3572724426598f4e44/server/main.lua#L35-L45
This should return success or failure and the optional error that occurred allowing the resource to retry
latest commit
n/a
Plates should be generated in a sql procedure or in a transaction.
Summary
Inserting a vehicle doesn't check for duplicate plates
Reproduction
Insert a vehicle with the same plate as an existing vehicle
Expected behavior
Return an error to the calling resource
Actual behavior
SQL error and potentially hang resource depending on how the export was called.
Additional context
https://github.com/Qbox-project/qbx_vehicles/blob/0198d9dee99f3cf0ff174a3572724426598f4e44/server/main.lua#L35-L45
This should return success or failure and the optional error that occurred allowing the resource to retry
Current Version
latest commit
Custom Resources
n/a