Skip to content

Commit db40eb7

Browse files
committed
use wipe to clean cache
1 parent e25b49a commit db40eb7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

LibGetFrame-1.0.lua

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ if not LibStub then error(MAJOR_VERSION .. " requires LibStub.") end
44
local lib = LibStub:NewLibrary(MAJOR_VERSION, MINOR_VERSION)
55
if not lib then return end
66

7-
local GetPlayerInfoByGUID, UnitExists, IsAddOnLoaded, C_Timer, UnitIsUnit, SecureButton_GetUnit = GetPlayerInfoByGUID, UnitExists, IsAddOnLoaded, C_Timer, UnitIsUnit, SecureButton_GetUnit
7+
local GetPlayerInfoByGUID, UnitExists, IsAddOnLoaded, C_Timer, UnitIsUnit, SecureButton_GetUnit, wipe = GetPlayerInfoByGUID, UnitExists, IsAddOnLoaded, C_Timer, UnitIsUnit, SecureButton_GetUnit, wipe
88

99
local maxDepth = 50
1010

@@ -87,7 +87,7 @@ end
8787

8888
local function ScanForUnitFrames()
8989
C_Timer.After(1, function()
90-
GetFramesCache = {}
90+
wipe(GetFramesCache)
9191
ScanFrames(UIParent, 0)
9292
end)
9393
end

0 commit comments

Comments
 (0)