Skip to content

Commit 2276aec

Browse files
committed
Fixed error when calling APIs early in the loading process
1 parent daa4af6 commit 2276aec

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

LibTalentTree-1.0.lua

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
-- the data for LibTalentTree will be loaded (and cached) from blizzard's APIs when the Lib loads
22
-- @curseforge-project-slug: libtalenttree@
33

4-
local MAJOR, MINOR = "LibTalentTree-1.0", 25;
4+
local MAJOR, MINOR = "LibTalentTree-1.0", 26;
55
--- @class LibTalentTree-1.0
66
local LibTalentTree = LibStub:NewLibrary(MAJOR, MINOR);
77

@@ -341,6 +341,9 @@ do
341341

342342
forceBuildCache = function()
343343
for classID = frame.currentClassID + 1, frame.numClasses do
344+
if classID == 1 then
345+
initCache();
346+
end
344347
buildPartialCache(classID);
345348
end
346349
onCacheCompleted();

0 commit comments

Comments
 (0)