Skip to content

Commit b52802d

Browse files
committed
fixed an error with the new keystone tooltip module
1 parent a3f7e61 commit b52802d

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

modules/showScoreOnKeystoneTooltip.lua

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,12 @@ function Module:OnTooltipShow(tooltip)
4141
local _, itemLink = tooltip:GetItem();
4242
if not itemLink then return end
4343

44-
if not C_Item.IsItemKeystoneByID(itemLink:match('item:(%d+)')) then return end
45-
46-
local mapId = itemLink:match(string.format(':%s:(%%d+):', Enum.ItemModification.KeystoneMapChallengeModeID));
44+
local mapId = itemLink:match('keystone:%d+:(%d+)');
45+
if not mapId then
46+
local itemId = itemLink:match('item:(%d+)');
47+
if not itemId or not C_Item.IsItemKeystoneByID(itemId) then return end
48+
mapId = itemLink:match(string.format(':%s:(%%d+):', Enum.ItemModification.KeystoneMapChallengeModeID));
49+
end
4750
if not mapId then return end
4851

4952
local overallInfo = Util:GetOverallInfoByMapId(mapId);

0 commit comments

Comments
 (0)