function StaffCheck(source) local staff = false if Config.Core:upper() == 'ESX'then local player = Core.GetPlayerFromId(source) local playerGroup = player.getGroup() for i, Group in ipairs(Config.AdminGroups) do if playerGroup == Group then staff = true break end end elseif Config.Core:upper() == 'QBCORE' then for i, Group in ipairs(Config.AdminGroups) do if Core.Functions.HasPermission(source, Group) or IsPlayerAceAllowed(source, Group) or IsPlayerAceAllowed(source, 'command') then staff = true break end end end return staff end