Quantcast

Fix TotemExpires and TotemPresent when passed "totem=..."

Johnny C. Lam [11-04-13 - 18:59]
Fix TotemExpires and TotemPresent when passed "totem=..."

This was broken in r1074 during a code cleanup.

git-svn-id: svn://svn.curseforge.net/wow/ovale/mainline/trunk@1123 d5049fe3-3747-40f7-a4b5-f36d6801af5f
Filename
OvaleCondition.lua
diff --git a/OvaleCondition.lua b/OvaleCondition.lua
index 250c8e5..bf4b2c1 100644
--- a/OvaleCondition.lua
+++ b/OvaleCondition.lua
@@ -4061,7 +4061,7 @@ OvaleCondition.conditions.totemexpires = function(condition)
 	if type(totemId) ~= "number" then
 		totemId = OVALE_TOTEMTYPE[totemId]
 	end
-	local startTime, duration = select(3, API_GetTotemInfo(totemId))
+	local totemName, startTime, duration = select(2, API_GetTotemInfo(totemId))
 	if not startTime then
 		return TestBoolean(true)
 	end
@@ -4089,7 +4089,7 @@ OvaleCondition.conditions.totempresent = function(condition)
 	if type(totemId) ~= "number" then
 		totemId = OVALE_TOTEMTYPE[totemId]
 	end
-	local startTime, duration = select(3, API_GetTotemInfo(totemId))
+	local totemName, startTime, duration = select(2, API_GetTotemInfo(totemId))
 	if not startTime then
 		return nil
 	end