From 01c735d94316eb34b031e5436aaae2bb09805edf Mon Sep 17 00:00:00 2001 From: filtered <176114999+webfiltered@users.noreply.github.com> Date: Sat, 12 Jul 2025 09:05:58 +1000 Subject: [PATCH] Fix cannot check widget value if undefined (#4433) --- src/utils/executionUtil.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/utils/executionUtil.ts b/src/utils/executionUtil.ts index 5310dbb48..a0047d716 100644 --- a/src/utils/executionUtil.ts +++ b/src/utils/executionUtil.ts @@ -145,9 +145,9 @@ export const graphToPrompt = async ( const resolvedInput = node.resolveInput(i) if (!resolvedInput) continue - // Input resolved to a SubgraphNode widget - const { value } = resolvedInput - if (value) { + // Resolved to an actual widget value rather than a node connection + if (resolvedInput.widgetInfo) { + const { value } = resolvedInput.widgetInfo inputs[input.name] = Array.isArray(value) ? { __value__: value } : value continue }