Skip to content

Commit 19c3de3

Browse files
committed
Fix secret error in FigureNPCGuild
If we can't read the tooltip line due to secrets, we can't extract the guild or any other info from it. Fixes #19
1 parent 79437de commit 19c3de3

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

Categories/TooltipScanning.lua

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ local GetClassicExpansionLevel = GetClassicExpansionLevel
1616
DogTag_Unit_funcs[#DogTag_Unit_funcs+1] = function(DogTag_Unit, DogTag)
1717

1818
local L = DogTag_Unit.L
19+
local issecretvalue = DogTag.issecretvalue
1920

2021
local tt
2122
if not C_TooltipInfo then
@@ -93,7 +94,7 @@ local function FigureNPCGuild(unit)
9394
elseif tt then
9495
left_2 = tt.left[2] and tt.left[2]:GetText() or nil
9596
end
96-
if not left_2 or left_2:find(LEVEL_start) then
97+
if not left_2 or issecretvalue(left_2) or left_2:find(LEVEL_start) then
9798
return nil
9899
end
99100
if info and not TooltipLineCouldBeGuild(info.lines[2]) then

0 commit comments

Comments
 (0)