Fixed nil entity error

This commit is contained in:
Timo Smit 2017-01-22 12:32:17 +01:00
parent f39284074b
commit 5df8c2874f

View file

@ -137,7 +137,7 @@ function commands.log(clientId, command, cmdArguments)
cmdClient = tonumber(cmdArguments[1])
end
if cmdClient ~= -1 and et.gentity_get(cmdClient, "pers.netname") then
if cmdClient ~= -1 and cmdClient ~= nil and et.gentity_get(cmdClient, "pers.netname") then
victimId = cmdClient
end
end