Adding missed local variables.
Salvatore Lopiparo [07-25-16 - 22:51]
Adding missed local variables.
diff --git a/code.lua b/code.lua
index 69b64c4..0103395 100644
--- a/code.lua
+++ b/code.lua
@@ -301,7 +301,7 @@ end
function CanIMogIt:GetAppearances()
-- Gets a table of all the appearances known to a character.
C_TransmogCollection.ClearSearch()
- appearances = {}
+ local appearances = {}
for categoryID=1,28 do
categoryAppearances = C_TransmogCollection.GetCategoryAppearances(categoryID)
for i, categoryAppearance in pairs(categoryAppearances) do
diff --git a/database.lua b/database.lua
index 1cf3fb1..a358f96 100644
--- a/database.lua
+++ b/database.lua
@@ -108,7 +108,7 @@ function Database:UpdateAppearances()
Updates the database with the current appearances,
adding or removing as needed.
]]
- appearances = CanIMogIt:GetAppearances()
+ local appearances = CanIMogIt:GetAppearances()
for appearanceID, appearance in pairs(appearances) do
if appearance.isCollected then
self:AddAppearance(appearanceID)
@@ -175,7 +175,7 @@ function Database:GetItemInfoReceived()
getItemInfoReceivedCount = getItemInfoReceivedCount + 1
if getItemInfoReceivedCount >= 300 or tablelength(CanIMogIt.sourceIDQueue) <= 300 then
getItemInfoReceivedCount = 0
- done = {}
+ local done = {}
for sourceID, appearanceID in pairs(CanIMogIt.sourceIDQueue) do
local itemLink = select(6, C_TransmogCollection.GetAppearanceSourceInfo(sourceID))
if not string.find(itemLink, '|h%[%]|h') then