Skip to content

Commit

Permalink
Fix error on non-sod classic era (fixes #2)
Browse files Browse the repository at this point in the history
  • Loading branch information
Numynum authored Nov 17, 2024
1 parent 02c8364 commit 47d8b50
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions UnifiedProfileManager.lua
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ local AceDB = LibStub('AceDB-3.0');
local AceDBOptions = LibStub('AceDBOptions-3.0');
local AceConfig = LibStub('AceConfig-3.0');
local AceConfigDialog = LibStub('AceConfigDialog-3.0');
local LibDualSpec = LibStub('LibDualSpec-1.0');
-- LibDualSpec does not load on non-SoD classic era
local LibDualSpec = LibStub('LibDualSpec-1.0', true);

local function SortAddons(name1, name2)
return strcmputf8i(StripHyperlinks(name1), StripHyperlinks(name2)) < 0;
Expand Down Expand Up @@ -444,7 +445,7 @@ end
function UPM:GetAceDBOptionsTable(db)
local options = DeepCopyTable(AceDBOptions:GetOptionsTable(db), db);

local isLibDualSpec = LibDualSpec.registry[db] and true or false;
local isLibDualSpec = LibDualSpec and LibDualSpec.registry[db] and true or false;
if isLibDualSpec then
LibDualSpec:EnhanceOptions(options, db);
end
Expand Down

0 comments on commit 47d8b50

Please sign in to comment.