1
0
Fork 0
forked from Simnation/Main

Update server.lua

This commit is contained in:
Miho931 2025-06-25 12:37:14 +02:00
parent fd474d93ca
commit f6eb5db14e

View file

@ -43,8 +43,7 @@ AddEventHandler('mh_jobgarage:DeleteFromList', function(plate)
local _source = source
local Player = QBCore.Functions.GetPlayer(_source)
local pedid = Player.PlayerData.citizenid
local keycounter = await(MySQL.query("SELECT value FROM mh_jobgarage WHERE plate = ?", {plate}))
keycounter = (keycounter and keycounter[1]) and keycounter[1].value or 0
local keycounter = MySQL.Sync.fetchScalar("SELECT value FROM mh_jobgarage WHERE plate = ?", {plate}) or 0
if keycounter == nil then
TriggerClientEvent('mh_jobgarage:notify', _source, "Schlüsselkasten", "Fehler, versuche es Später erneut.", "inform")