Sometimes self is corrupted when first mousing over a unit frame, before mousing over any world unit. Here's a temporary fix till I find the source of the problem.
Scott Sibley [11-04-10 - 02:21]
Sometimes self is corrupted when first mousing over a unit frame, before mousing over any world unit. Here's a temporary fix till I find the source of the problem.
diff --git a/Modules/UnitTooltip/UnitTooltip.lua b/Modules/UnitTooltip/UnitTooltip.lua
index 57b9dbc..d6f9fda 100644
--- a/Modules/UnitTooltip/UnitTooltip.lua
+++ b/Modules/UnitTooltip/UnitTooltip.lua
@@ -219,7 +219,7 @@ return "Alive"
name = "Health",
left = 'return "Health:"',
right = [[
-if not UnitExists(unit) then self:Stop(); return self.lastHealth end
+if not UnitExists(unit) and self.Stop then self:Stop(); return self.lastHealth end
local health, maxHealth = UnitHealth(unit), UnitHealthMax(unit)
local r, g, b = HPColor(health, maxHealth)
local value = "Unknown"
@@ -241,7 +241,7 @@ return value
return PowerName(unit)
]],
right = [[
-if not UnitExists(unit) then self:Stop(); return self.lastMana end
+if not UnitExists(unit) and self.Stop then self:Stop(); return self.lastMana end
local mana = UnitMana(unit)
local maxMana = UnitManaMax(unit)
local r, g, b = PowerColor(nil, unit)