refactor(client/progress): don't clear progress on cancel

Sending "progressCancel" to NUI will cause a transition and then
trigger "progressComplete" with a slight delay (~100ms).

Should look better when people queue up progress bars.
This commit is contained in:
Linden
2023-05-05 14:51:52 +10:00
parent c94d019f67
commit 878763867a

View File

@@ -147,10 +147,8 @@ local function startProgress(data)
end
playerState.invBusy = false
local cancel = progress == false
progress = nil
if cancel then
if progress == false then
SendNUIMessage({ action = 'progressCancel' })
return false
end