Skip to content

Commit e13f9f5

Browse files
committed
Fix info being displayed when leveling and learning a choice node (fixes #34)
1 parent ef7c672 commit e13f9f5

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

modules/Leveling.lua

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -94,12 +94,12 @@ function Module:GetSpellIDMap()
9494
local nodes = C_Traits.GetTreeNodes(treeID)
9595
for _, nodeID in ipairs(nodes) do
9696
local nodeInfo = C_Traits.GetNodeInfo(configID, nodeID)
97-
for _, entryID in ipairs(nodeInfo.entryIDs) do
98-
local entryInfo = C_Traits.GetEntryInfo(configID, entryID)
97+
if nodeInfo.activeEntry and nodeInfo.activeEntry.entryID and nodeInfo.activeEntry.rank > 0 then
98+
local entryInfo = C_Traits.GetEntryInfo(configID, nodeInfo.activeEntry.entryID)
9999
if entryInfo and entryInfo.definitionID then
100100
local definitionInfo = C_Traits.GetDefinitionInfo(entryInfo.definitionID)
101101
if definitionInfo.spellID then
102-
map[definitionInfo.spellID] = nodeInfo.activeRank
102+
map[definitionInfo.spellID] = nodeInfo.activeEntry.rank
103103
end
104104
end
105105
end

0 commit comments

Comments
 (0)