v0.3.3 - Fix "By ID" search not finding nodes on frontend 1.47+
Node IDs became strings on ComfyUI frontend 1.47+ (previously numbers). AF_Find_Nodes_FindNodeById() used a strict === comparison against a parseInt'd search term, so it silently stopped matching any node. Now compares IDs as strings so it works across old and new frontends.
This commit is contained in:
@@ -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
|
||||
|
||||
+1
-1
@@ -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",
|
||||
|
||||
+1
-1
@@ -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 = []
|
||||
|
||||
|
||||
@@ -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) {
|
||||
|
||||
Reference in New Issue
Block a user