From aae7e034f3bb39cc24e6f3fe5b2fa33a042c06e6 Mon Sep 17 00:00:00 2001 From: shagu Date: Mon, 27 Feb 2017 20:14:06 +0100 Subject: [PATCH] bags: only update cooldown if frame exists --- modules/bags.lua | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/modules/bags.lua b/modules/bags.lua index 5fe21db8..36dd9e35 100644 --- a/modules/bags.lua +++ b/modules/bags.lua @@ -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