Add _source line 495
This commit is contained in:
Bryz LARMITE
2018-04-06 23:24:35 +02:00
committed by GitHub
parent aed4db306e
commit 360d968e5b
+3 -2
View File
@@ -492,7 +492,8 @@ AddEventHandler('esx_policejob:forceBlip', function()
end)
ESX.RegisterServerCallback('esx_policejob:isCop', function(source, cb)
local xPlayer = ESX.GetPlayerFromId(source)
local _source = source
local xPlayer = ESX.GetPlayerFromId(_source)
cb(xPlayer ~= nil and xPlayer.job ~= nil and xPlayer.job.name == 'police')
end)
@@ -501,4 +502,4 @@ AddEventHandler('onResourceStart', function(resource)
Citizen.Wait(5000)
TriggerClientEvent('esx_policejob:updateBlip', -1)
end
end)
end)