Change for function ns:GetSource(searchedID): Manual Loot Table is now preferred source

This commit is contained in:
telkar-rg
2023-11-03 12:59:33 +01:00
parent 150ab875bc
commit 0353ba71ae
+9 -8
View File
@@ -943,14 +943,6 @@ function ns:GetSource(searchedID)
DataStore_Inventory, DataStore_Inventory,
} }
local domain, subDomain
for _, provider in pairs(DataProviders) do
domain, subDomain = provider:GetSource(searchedID)
if domain and subDomain then
return domain, subDomain
end
end
-- extremely fast: takes from 0.3 to 3 ms max, depends on the location of the item in the table (obviously longer if the item is at the end) -- extremely fast: takes from 0.3 to 3 ms max, depends on the location of the item in the table (obviously longer if the item is at the end)
for Instance, BossList in pairs(lootTable) do for Instance, BossList in pairs(lootTable) do
for Boss, LootList in pairs(BossList) do for Boss, LootList in pairs(BossList) do
@@ -961,6 +953,15 @@ function ns:GetSource(searchedID)
end end
end end
end end
local domain, subDomain
for _, provider in pairs(DataProviders) do
domain, subDomain = provider:GetSource(searchedID)
if domain and subDomain then
return domain, subDomain
end
end
return nil return nil
end end