Skip to content

Commit

Permalink
fix(server/main): use correct export values for HasPrimaryGroup (#117)
Browse files Browse the repository at this point in the history
* Fixed job and gang garages

* Update main.lua
  • Loading branch information
Thomasdev18 authored Jul 6, 2024
1 parent 9ca2ee9 commit 483be9f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions server/main.lua
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ function GetPlayerVehicleFilter(source, garageName)
end

local function getCanAccessGarage(player, garage)
if garage.groups and not exports.qbx_core:HasPrimaryGroup(garage.groups, QBX.PlayerData) then
if garage.groups and not exports.qbx_core:HasPrimaryGroup(player.PlayerData.source, garage.groups) then
return false
end
if garage.canAccess ~= nil and not garage.canAccess(player.PlayerData.source) then
Expand Down Expand Up @@ -242,4 +242,4 @@ lib.callback.register('qbx_garages:server:payDepotPrice', function(source, vehic
player.Functions.RemoveMoney('bank', depotPrice, 'paid-depot')
return true
end
end)
end)

0 comments on commit 483be9f

Please sign in to comment.