From 8868b16785ea6499f669ca08e4ea305c00e84a54 Mon Sep 17 00:00:00 2001 From: Parnic Date: Sat, 25 Sep 2021 09:34:44 -0500 Subject: [PATCH] Fix FocusMana event registration on Classic builds Thanks to Lethay's comments on WowAce. --- changelog.md | 4 ++++ modules/FocusMana.lua | 4 ++-- this_version.md | 5 ++--- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/changelog.md b/changelog.md index 8cc481a..d240045 100644 --- a/changelog.md +++ b/changelog.md @@ -1,5 +1,9 @@ # Changelog +v1.13.9: + +- Fixed FocusMana modules attempting to register invalid events in Classic builds. + v1.13.8.1: - Updated TOC for BC-Classic and Classic. diff --git a/modules/FocusMana.lua b/modules/FocusMana.lua index 0a66da1..1e90ec1 100644 --- a/modules/FocusMana.lua +++ b/modules/FocusMana.lua @@ -39,9 +39,9 @@ end function FocusMana.prototype:Enable(core) FocusMana.super.prototype.Enable(self, core) - if IceHUD.WowVer >= 40000 then + if not IceHUD.PerPowerEventsExist then self:RegisterEvent(IceHUD.UnitPowerEvent, "UpdateEvent") - if IceHUD.WowVer < 80000 then + if IceHUD.EventExistsUnitMaxPower then self:RegisterEvent("UNIT_MAXPOWER", "UpdateEvent") end else diff --git a/this_version.md b/this_version.md index d5fa027..87115b6 100644 --- a/this_version.md +++ b/this_version.md @@ -1,6 +1,5 @@ # Changelog -v1.13.8.1: +vNext: -- Fixed Paladin GCD not functioning in BC-Classic. -- Updated TOC for BC-Classic and Classic. +- Fixed FocusMana modules attempting to register invalid events in Classic builds.