I am confused how to make Datastores Safely save information. I am wondering how to make sure an error doesn't lose someone all of their Currency even if roblox is erroring really bad.
Should I do;
pcall(function()
local DSCurrency = DSplrStats:GetAsync("DSCurrency")
if DSCurrency then
Stats.UpdateStat(uID,"Currency",DSCurrency)
end
end)))
or maybe;
coroutine.resume(coroutine.create(pcall(function()
local DSCurrency = DSplrStats:GetAsync("DSCurrency")
if DSCurrency then
Stats.UpdateStat(uID,"Currency",DSCurrency)
end
end)))
