bags: only update cooldown if frame exists

This commit is contained in:
shagu
2017-02-27 20:14:06 +01:00
parent 4ea0454a32
commit aae7e034f3
+3 -1
View File
@@ -82,7 +82,9 @@ pfUI:RegisterModule("bags", function ()
if bag == -2 and pfUI.bag.showKeyring == true then bagsize = GetKeyRingSize() end
for slot=1, bagsize do
if pfUI.bags[bag].slots[slot].frame.hasItem then
ContainerFrame_UpdateCooldown(bag, pfUI.bags[bag].slots[slot].frame)
if _G[pfUI.bags[bag].slots[slot].frame:GetName() .. "Cooldown"] then
ContainerFrame_UpdateCooldown(bag, pfUI.bags[bag].slots[slot].frame)
end
end
end
end