unitframes: clear stale aura swirl on target swap

Buff and debuff slots only called CooldownFrame_SetTimer on the
`expirationTime > 0` (or `duration > 0` for buffs) paths. When the new
target's aura at the same slot index had neither — permanent / passive
auras like Retribution Aura — neither branch fired and the slot kept
displaying the previous target's swirl/timer.

Add an explicit 0/0/0 clear on every path that doesn't set a real
timer, so the button always starts from a known state.

Fixes #13.
This commit is contained in:
Brues
2026-06-28 12:41:23 -05:00
parent 8bf6672114
commit 9bdde06150
+8
View File
@@ -1902,6 +1902,8 @@ function pfUI.uf:RefreshUnit(unit, component)
end
if duration > 0 then
CooldownFrame_SetTimer(unit.buffs[i].cd, start, duration, 1)
else
CooldownFrame_SetTimer(unit.buffs[i].cd, 0, 0, 0)
end
elseif aura.duration > 0 then
local guid = UnitGUID(unitstr)
@@ -1912,6 +1914,8 @@ function pfUI.uf:RefreshUnit(unit, component)
else
CooldownFrame_SetTimer(unit.buffs[i].cd, 0, 0, 0)
end
else
CooldownFrame_SetTimer(unit.buffs[i].cd, 0, 0, 0)
end
else
unit.buffs[i]:Hide()
@@ -2005,7 +2009,11 @@ function pfUI.uf:RefreshUnit(unit, component)
end
if duration > 0 then
CooldownFrame_SetTimer(unit.debuffs[i].cd, start, duration, 1)
else
CooldownFrame_SetTimer(unit.debuffs[i].cd, 0, 0, 0)
end
else
CooldownFrame_SetTimer(unit.debuffs[i].cd, 0, 0, 0)
end
if stacks > 1 then