Skip to content

Commit

Permalink
[Bugfix] Fix issue with Aura tracking when either buff or debuff widg…
Browse files Browse the repository at this point in the history
…et is disabled
  • Loading branch information
Krealle committed Sep 2, 2024
1 parent b5b8e69 commit b53e856
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion Widgets/Auras/Auras.lua
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ end
-------------------------------------------------

---@param self CellAuraIcons
local function Enable(self) -- Has unique name because of some obscure referncing bug?
local function Enable(self)
self._owner:AddEventListener("UNIT_AURA", self.Update)

self:Show()
Expand All @@ -228,6 +228,13 @@ end

---@param self CellAuraIcons
local function Disable(self)
-- We don't want to remove the event listener if we still have one of the widgets enabled
if self._owner:IsVisible() then
if self._owner.widgets.buffs.enabled or self._owner.widgets.debuffs.enabled then
return
end
end

self._owner:RemoveEventListener("UNIT_AURA", self.Update)
end

Expand Down

0 comments on commit b53e856

Please sign in to comment.