Quantcast

In addon:AddRecipe(): Don't pre-initialize all of the filter "flags" to false, as nil will suffice - significantly curtails RAM usage.

James D. Callahan III [03-31-10 - 23:27]
In addon:AddRecipe(): Don't pre-initialize all of the filter "flags" to false, as nil will suffice - significantly curtails RAM usage.
Filename
ARL.lua
diff --git a/ARL.lua b/ARL.lua
index ad30893..bcd0c72 100644
--- a/ARL.lua
+++ b/ARL.lua
@@ -870,11 +870,6 @@ function addon:AddRecipe(spell_id, skill_level, item_id, quality, profession, sp
 	if not recipe.name then
 		self:Print(strformat(L["SpellIDCache"], spell_id))
 	end
-
-	-- Set all the flags to be false, will also set the padding spaces to false as well.
-	for i = 1, NUM_FILTER_FLAGS, 1 do
-		recipe["Flags"][i] = false
-	end
 	recipe_list[spell_id] = recipe
 end