From aac822402d81017023da8e1608a712cc58685801 Mon Sep 17 00:00:00 2001 From: Mojito-Fivem Date: Mon, 8 Nov 2021 17:36:11 +0000 Subject: [PATCH] fix(refactor/paycheckloop): Send to players source --- server/functions.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/functions.lua b/server/functions.lua index 5083c44..0293cdb 100644 --- a/server/functions.lua +++ b/server/functions.lua @@ -115,7 +115,7 @@ function PaycheckLoop() local Player = Players[i] if Player.PlayerData.job and Player.PlayerData.job.onduty and Player.PlayerData.job.payment > 0 then Player.Functions.AddMoney('bank', Player.PlayerData.job.payment) - TriggerClientEvent('QBCore:Notify', Players[i], 'You received your paycheck of $' .. Player.PlayerData.job.payment) + TriggerClientEvent('QBCore:Notify', Player.PlayerData.source, 'You received your paycheck of $' .. Player.PlayerData.job.payment) end end SetTimeout(QBCore.Config.Money.PayCheckTimeOut * (60 * 1000), PaycheckLoop)