Skip to content
This repository has been archived by the owner on Jun 16, 2024. It is now read-only.

Depreciated Blizzard API IsAddOnLoaded in various files #1

Closed
Myrroddin opened this issue Mar 6, 2024 · 1 comment · Fixed by #3
Closed

Depreciated Blizzard API IsAddOnLoaded in various files #1

Myrroddin opened this issue Mar 6, 2024 · 1 comment · Fixed by #3
Assignees
Labels
bug Something isn't working

Comments

@Myrroddin
Copy link

The Blizzard Lua API IsAddOnLoaded is depreciated and going away when The War Within launches. You use the API in the files located in the style folder.

Assuming you want backwards compatibility with Classic (Wrath) and Classic Era (Seasons, hardcore, and Classic Era), you need to add this line after creating the ns variable:

local ns = (select(2, ...))
local IsAddOnLoaded = C_AddOns and C_AddOns.IsAddOnLoaded or IsAddOnLoaded

-- the rest of the file here

See this URL for the API changes.

@fang2hou fang2hou self-assigned this Mar 6, 2024
@fang2hou fang2hou added the bug Something isn't working label Mar 6, 2024
@fang2hou
Copy link
Member

fang2hou commented Mar 6, 2024

Thanks for your nicely code review!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants