Skip to content

Commit

Permalink
Remove old Classic compatibility code
Browse files Browse the repository at this point in the history
  • Loading branch information
ntowle committed Oct 30, 2024
1 parent 7210932 commit 83c2cee
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 12 deletions.
1 change: 0 additions & 1 deletion .luacheckrc
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ ignore = {
globals = {
"CreateFrame",
"C_Spell",
"GetSpellInfo",
"GetActionInfo",
"hooksecurefunc",
"tinsert",
Expand Down
3 changes: 1 addition & 2 deletions HideButtonGlow.lua
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ local addonName, addon = ...
-- globals
local CreateFrame, GetActionInfo, DEFAULT_CHAT_FRAME, Settings = CreateFrame, GetActionInfo, DEFAULT_CHAT_FRAME, Settings

-- TWW uses C_Spell, compatibility code for older clients
local GetSpellName = C_Spell and C_Spell.GetSpellName or GetSpellInfo
local GetSpellName = C_Spell.GetSpellName

local eventFrame = CreateFrame("Frame")
eventFrame:SetScript("OnEvent", function(self, event, ...)
Expand Down
10 changes: 1 addition & 9 deletions options.lua
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,7 @@ local addonName, addon = ...
-- globals
local tinsert, tremove, tContains, tonumber = tinsert, tremove, tContains, tonumber

-- TWW uses C_Spell, compatibility code for older clients
local GetSpellName = C_Spell and C_Spell.GetSpellName or GetSpellInfo
local GetSpellInfo = C_Spell and C_Spell.GetSpellInfo or function(spellIdentifier)
local name, _, _, _, _, _, spellID = GetSpellInfo(spellIdentifier)
return {
["name"] = name,
["spellID"] = spellID,
}
end
local GetSpellName, GetSpellInfo = C_Spell.GetSpellName, C_Spell.GetSpellInfo

LibStub("AceConfigRegistry-3.0"):RegisterOptionsTable(addonName, function()
return {
Expand Down

0 comments on commit 83c2cee

Please sign in to comment.