i have two weird errors (more info below)
local success, errormessage pcall(function()
data = cb_ds:GetAsync(user_id)
end)
if success and data then
cb.Value = data
else
warn(player.Name .. " has no data")
print(data)
end
local success, errormessage pcall(function()
save_bux(player)
end)
if success then
print("data has been saved")
else
warn("data has not been saved")
end
there is a error on both of the “if success” and i dont understand why it isnt working, it works for stuff like this
local success, errormessage = pcall(function()
cb_ds:SetAsync(user_id, cb.Value)
end)
if success then
print("saved bux")
else
print("error on saving bux")
warn(errormessage)
but not any of those other two