Skip to content

Commit

Permalink
Merge pull request #345 from Qwerty1Verified/patch-2
Browse files Browse the repository at this point in the history
Fix: Use table length to check for vehicles
  • Loading branch information
GhzGarage authored Jan 31, 2024
2 parents fcdbf57 + cdbcb91 commit e3aade3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion server/main.lua
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ QBCore.Functions.CreateCallback('qb-garages:server:GetGarageVehicles', function(
else
vehicles = MySQL.rawExecute.await('SELECT * FROM player_vehicles WHERE citizenid = ? AND garage = ?', { citizenId, garage })
end
if not vehicles then
if #vehicles == 0 then
cb(nil)
return
end
Expand Down

0 comments on commit e3aade3

Please sign in to comment.