From d51b627cf6d23e434f14959dbe5697803880edf4 Mon Sep 17 00:00:00 2001 From: Parnic Date: Sun, 30 Sep 2012 21:22:16 +0000 Subject: [PATCH] - Ticket #157 - fixed an error when a channeled spell ends early due to being hit. (Thanks, cg110!) --- IceCastBar.lua | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/IceCastBar.lua b/IceCastBar.lua index c604d45..377e0d6 100644 --- a/IceCastBar.lua +++ b/IceCastBar.lua @@ -551,7 +551,11 @@ function IceCastBar.prototype:SpellCastChannelUpdate(event, unit) --IceHUD:Debug("SpellCastChannelUpdate", unit, UnitChannelInfo(unit)) local spell, rank, displayName, icon, startTime, endTime = UnitChannelInfo(unit) - self.actionDuration = endTime/1000 - self.actionStartTime + if not spell then + self.actionDuration = 0 + else + self.actionDuration = endTime/1000 - self.actionStartTime + end end function IceCastBar.prototype:SpellCastChannelStop(event, unit)