Skip to content

Commit

Permalink
Classic WoW hot fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Tercioo committed Aug 9, 2019
1 parent 9071980 commit a1b7153
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions functions/spellcache.lua
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,9 @@ do
if (t) then
local spellid = t [1]
local name, _, icon = _GetSpellInfo (spellid)
_rawset (_detalhes.spellcache, spellid, {name, 1, icon})
if (name) then
_rawset (_detalhes.spellcache, spellid, {name, 1, icon})
end
return tremove (_detalhes.savedCustomSpells, index)
end

Expand All @@ -231,10 +233,13 @@ do
_detalhes.getspellinfo = function (spellid) return _unpack (_detalhes.spellcache[spellid]) end
_detalhes.GetSpellInfo = _detalhes.getspellinfo

--> overwrite SpellInfo if spell is a Dot, so GetSpellInfo will return the name modified
--> overwrite SpellInfo if the spell is a DoT, so Details.GetSpellInfo will return the name modified
function _detalhes:SpellIsDot (spellid)
local nome, rank, icone = _GetSpellInfo (spellid)
_rawset (_detalhes.spellcache, spellid, {nome .. Loc ["STRING_DOT"], rank, icone})
local spellName, rank, spellIcon = _GetSpellInfo (spellid)

if (spellName) then
_rawset (_detalhes.spellcache, spellid, {spellName .. Loc ["STRING_DOT"], rank, spellIcon})
end
end

--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Expand Down

0 comments on commit a1b7153

Please sign in to comment.