Skip to content

Commit f2b103d

Browse files
author
LocalIdentity
committed
Fix crash on search for Megalomaniac on old tree
1 parent ee6cb35 commit f2b103d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/Classes/TradeQuery.lua

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -698,7 +698,9 @@ function TradeQueryClass:GetResultEvaluation(row_idx, result_index)
698698
local addedNodes = {}
699699
for nodeName in (result.item_string.."\r\n"):gmatch("Allocates (.-)\r?\n") do
700700
local node = self.itemsTab.build.spec.tree.notableMap[nodeName:lower()]
701-
addedNodes[node] = true
701+
if node and node.recipes ~= nil then
702+
addedNodes[node] = true
703+
end
702704
end
703705

704706
local output = self:ReduceOutput(calcFunc({ addNodes = addedNodes }))

0 commit comments

Comments
 (0)