BugSack

BugSack

7M Downloads

BugGrabber: Wrong usage of `GetAddOnInfo()` (all flavors of WoW)

2072 opened this issue ยท 1 comments

commented

Describe the problem

C_AddOns.GetAddOnInfo() has "recently" changed: it's 4th returned value is no longer reporting if an add-on is loaded but if it CAN be loaded for the current character. Which means that buggrabber will not enable itself if other error handling add-ons are installed but not enabled among other things (GetAddOnInfo() is used several times for different purposes).

You should replace all instances of

local _, _, _, enabled = GetAddOnInfo(???)

with

local _, enabled = IsAddOnLoaded(???)

What steps will reproduce the problem?

  1. /dump C_AddOns.GetAddOnInfo("BugSack") when BugSack is disabled
  2. observe the 4th returned value to be true

What version of the addon are you using? (Stating 'latest' is not useful)

v11.0.2 BugGrabber and v11.0.3 BugSack

Do you have an error log of what happened?

N/A

Any additional information? (example: WoW language if not English)

N/A

commented

Thanks. Your method won't work since it will return false for addons still to be loaded when logging in, but I fixed it using GetAddOnEnableState.