diff --git a/WeakAuras/GenericTrigger.lua b/WeakAuras/GenericTrigger.lua index 9ccc81d..38150e9 100644 --- a/WeakAuras/GenericTrigger.lua +++ b/WeakAuras/GenericTrigger.lua @@ -1234,6 +1234,9 @@ function GenericTrigger.Add(data, region) triggerFunc = WeakAuras.LoadFunction("return "..(trigger.custom or ""), id); if (trigger.custom_type == "stateupdate") then tsuConditionVariables = WeakAuras.LoadFunction("return function() return \n" .. (trigger.customVariables or "") .. "\n end"); + if not tsuConditionVariables then + tsuConditionVariables = function() return end + end end if(trigger.custom_type == "status" or trigger.custom_type == "event" and trigger.custom_hide == "custom") then diff --git a/WeakAuras/compat.lua b/WeakAuras/compat.lua index 197a145..f7ac9be 100644 --- a/WeakAuras/compat.lua +++ b/WeakAuras/compat.lua @@ -238,7 +238,11 @@ if not C_Timer or C_Timer._version ~= 2 then end function C_Timer.After(duration, callback) - return CreateTicker(duration, callback, 1) + AddDelayedCall({ + _remainingIterations = 1, + _delay = duration, + _callback = callback + }) end function C_Timer.NewTimer(duration, callback)