@@ -124,7 +124,7 @@ function TUM:InitItemSourceMap()
124124 self .itemSourceMapInitialized = false
125125 self .itemSourceMapProgress = 0
126126 self .itemSourceMapTotal = 0
127- self .itemSourceIDs = itemSourceIDs
127+ self .itemSourceIDs = TransmogUpgradeMasterCacheDB or itemSourceIDs
128128 --- @type table<number , TransmogCategoryAppearanceInfo[]>
129129 local categoryAppearances = {}
130130 for _ , category in pairs (Enum .TransmogCollectionType ) do
@@ -154,6 +154,8 @@ function TUM:InitItemSourceMap()
154154 end
155155 end
156156 self .itemSourceMapInitialized = true
157+ self .itemSourceIDs = itemSourceIDs
158+ TransmogUpgradeMasterCacheDB = itemSourceIDs
157159 end
158160 local resumeFunc = coroutine.wrap (iterateAppearances )
159161 local ticker
@@ -261,6 +263,7 @@ function TUM:IsAppearanceMissing(itemLink, classID, debugLines)
261263
262264 return nil , nil , nil , nil , nil
263265 end
266+ classID = classID or playerClassID
264267 local canCatalyse , canUpgradeToNextBreakpoint = false , false
265268 local catalystMissing , catalystUpgradeMissing , upgradeMissing = nil , nil , nil
266269
@@ -424,16 +427,17 @@ end
424427--- @return boolean isCacheWarmedUp
425428--- @return number progress # a number between 0 and 1, where 1 means caching has finished
426429function TUM :IsCacheWarmedUp ()
427- if not self .itemSourceMapInitialized then
430+ if not TransmogUpgradeMasterCacheDB and not self .itemSourceMapInitialized then
428431 return false , self .itemSourceMapProgress / self .itemSourceMapTotal
429432 end
430433 return true , 1
431434end
432435
433436--- @return boolean loading
434437function TUM :ShowLoadingTooltipIfLoading (tooltip )
435- if self .itemSourceMapInitialized then return false end
436- local _ , progress = self :IsCacheWarmedUp ()
438+ local warmedUp , progress = self :IsCacheWarmedUp ()
439+ if warmedUp then return false end
440+
437441 local text = string.format (" TransmogUpgradeMaster is loading (%.0f%%)" , progress * 100 )
438442 tooltip :AddLine (text , nil , nil , nil , true )
439443
0 commit comments