Skip to content

Commit

Permalink
disable events on unsupported classes
Browse files Browse the repository at this point in the history
  • Loading branch information
coolmodi committed Apr 27, 2020
1 parent 743b980 commit f25fe44
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion events.lua
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
local _addonName, _addon = ...;
local L = _addon:GetLocalization();

-- dirty fix to "disable" the addon preventing errors on unsupported classes
-- TODO: Remove when classes are supported
local _, class = UnitClass("player");
if class == "WARRIOR" or class == "ROGUE" or class == "HUNTER" then
_addon:PrintError("Class not (yet) supported, addon won't work!");
return;
end

local frame = CreateFrame("Frame");
local handlers = {};
Expand Down

0 comments on commit f25fe44

Please sign in to comment.