changed dataSource from if statement to global table

This commit is contained in:
Anch
2022-08-18 20:59:13 +12:00
parent 437a9533f1
commit cf856bf830
2 changed files with 2 additions and 11 deletions
+1 -10
View File
@@ -453,16 +453,7 @@ function AtlasLoot:ShowItemsFrame(dataID, dataSource, tablenum)
Atlasloot_HeaderLabel:Hide();
local dataSource_backup = dataSource;
if dataID == "SearchResult" or dataSource == " AtlasLootCharDB" then
dataSource = AtlasLootCharDB;
elseif dataSource == "AtlasLoot_TokenData" then
dataSource = AtlasLoot_TokenData;
elseif dataSource == "AtlasLootWishList" then
dataSource = AtlasLootWishList;
else
dataSource = AtlasLoot_Data;
end
dataSource = _G[dataSource] or AtlasLoot_Data;
-- Check to see if Atlas is loaded and the table has a map
if dataSource[dataID].Map and ATLASLOOT_ATLASLOADED then