Skip to content

Commit

Permalink
fix child charges and duration
Browse files Browse the repository at this point in the history
  • Loading branch information
jordonwow committed Nov 28, 2023
1 parent 77e0c10 commit 963eaf6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions OmniBar.lua
Original file line number Diff line number Diff line change
Expand Up @@ -865,6 +865,9 @@ function OmniBar:AddSpellCast(event, sourceGUID, sourceName, sourceFlags, spellI

local now = GetTime()

local charges = addon.Cooldowns[spellID].charges
local duration = customDuration or GetCooldownDuration(addon.Cooldowns[spellID])

-- make sure spellID is parent
spellID = addon.Cooldowns[spellID].parent or spellID

Expand All @@ -880,9 +883,6 @@ function OmniBar:AddSpellCast(event, sourceGUID, sourceName, sourceFlags, spellI
-- only track players and their pets
if (not ownerName) and bit_band(sourceFlags, COMBATLOG_OBJECT_TYPE_PLAYER) == 0 then return end

local duration = customDuration or GetCooldownDuration(addon.Cooldowns[spellID])
local charges = addon.Cooldowns[spellID].charges

-- child doesn't have custom charges, use parent
if (not charges) then
charges = addon.Cooldowns[spellID].charges
Expand Down

0 comments on commit 963eaf6

Please sign in to comment.