diff --git a/CHANGELOG.md b/CHANGELOG.md index 4f8ea32..3c2960d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,8 @@ ## Changelog +### v0.3.3 +- Fixed "By ID" search not finding nodes - ComfyUI frontend 1.47+ changed node IDs from numbers to strings, and the lookup used a strict `===` comparison that only ever matched the old number type. Now compares IDs as strings so it works on old and new frontends alike. + ### v0.3.2 - Keyboard shortcut to open the Find Nodes panel is now configurable via ComfyUI Settings → AF - Nodes → AF - Find Nodes → Shortcuts - Set to "Disabled" to turn off the shortcut entirely diff --git a/package.json b/package.json index 2a0ee7f..fa9b416 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "comfyui-af-find-nodes", - "version": "0.3.2", + "version": "0.3.3", "description": "A ComfyUI extension that allows you to find and locate nodes by their ID, title, pack, or type in complex workflows.", "author": "Alex Furer", "license": "MIT", diff --git a/pyproject.toml b/pyproject.toml index 7fa081f..09c32e2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,7 +1,7 @@ [project] name = "comfyui-af-find-nodes" description = "A ComfyUI extension that allows you to find and locate nodes by their ID, title, pack, or type in complex workflows." -version = "0.3.2" +version = "0.3.3" license = {file = "LICENSE"} dependencies = [] diff --git a/web/AF_Find_Nodes.js b/web/AF_Find_Nodes.js index e96044d..8711db8 100644 --- a/web/AF_Find_Nodes.js +++ b/web/AF_Find_Nodes.js @@ -2170,7 +2170,8 @@ class AF_Find_Nodes_Widget { AF_Find_Nodes_FindNodeById(nodeId) { if (!app.graph || !app.graph.nodes) return null; - return app.graph.nodes.find(node => node.id === nodeId); + // Node ids are strings on frontend 1.47+, numbers on older versions - compare as strings + return app.graph.nodes.find(node => String(node.id) === String(nodeId)); } AF_Find_Nodes_HighlightNode(node) {