Skip to content

Commit

Permalink
fix(server/inventory): owned vehicle plate dbid for esx/qb
Browse files Browse the repository at this point in the history
Resolves #1480.
  • Loading branch information
thelindat committed Sep 12, 2023
1 parent 576d6ee commit e2bedb4
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions modules/inventory/server.lua
Original file line number Diff line number Diff line change
Expand Up @@ -568,9 +568,10 @@ function Inventory.Create(id, label, invType, slots, weight, maxWeight, owner, i
self.id = ('%s:%s'):format(self.id, owner)
end
else
self.dbId = id

if not invType:find(id) then
if string.find(id, '^glove') or string.find(id, '^trunk') then
self.dbId = id:sub(6)
else
self.dbId = id
self.id = (invType == 'glovebox' and 'glove' or invType) .. label
end
end
Expand Down

0 comments on commit e2bedb4

Please sign in to comment.