Skip to content

Commit

Permalink
fix(server/main): fix issue with obtaining playerdata
Browse files Browse the repository at this point in the history
fix(server/main): fix issue with obtaining playerdata
  • Loading branch information
FjamZoo authored Sep 14, 2024
2 parents 9b60fc2 + 5c40c08 commit cac540b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion server/main.lua
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ end
exports('addAccountMoney', AddAccountMoney)

local function getPlayerData(source, id)
local Player = GetPlayerObject(tonumber(id))
local Player = source and GetPlayerObject(source)
if not Player then Player = GetPlayerObjectFromID(id) end
if not Player then
local msg = ("Cannot Find Account(%s)"):format(id)
Expand Down

0 comments on commit cac540b

Please sign in to comment.