Skip to content

Commit

Permalink
Fix regression in remain time check
Browse files Browse the repository at this point in the history
Remain needs to be declared and initialized in the right scope.

Ticket-Nr: 1224
  • Loading branch information
InfusOnWoW authored and Stanzilla committed Sep 15, 2018
1 parent 436f5e2 commit be7b2e0
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions WeakAuras/Prototypes.lua
Original file line number Diff line number Diff line change
Expand Up @@ -2079,8 +2079,9 @@ WeakAuras.event_prototypes = {
end
if(trigger.use_remaining and trigger.genericShowOn ~= "showOnReady") then
local ret2 = [[
if (expirationTime) then
local remaining = expirationTime > 0 and (expirationTime - GetTime()) or 0;
local remaining = 0;
if (expirationTime and expirationTime > 0) then
remaining = expirationTime - GetTime();
local remainingCheck = %s;
if(remaining >= remainingCheck and remaining > 0) then
WeakAuras.ScheduleCooldownScan(expirationTime - remainingCheck);
Expand Down

0 comments on commit be7b2e0

Please sign in to comment.