Skip to content

armgit / dify

Public Imported from GitHub
0

Build Agentic workflows, RAG pipelines, with rich AI model and tool support on one collaborative workspace. Deploy on cloud, VPC, or self-hosted, so teams move from prototype to production without rebuilding the stack.

fix: code-block-missing-checks (#7002)

crazywoola7f18c06b0a17
diff --git a/web/app/components/workflow/nodes/_base/components/variable/utils.ts b/web/app/components/workflow/nodes/_base/components/variable/utils.ts
index d507af5d8d3..e48e6704adb 100644
--- a/web/app/components/workflow/nodes/_base/components/variable/utils.ts
+++ b/web/app/components/workflow/nodes/_base/components/variable/utils.ts
@@ -125,12 +125,14 @@ const formatItem = (
const {
outputs,
} = data as CodeNodeType
- res.vars = Object.keys(outputs).map((key) => {
- return {
- variable: key,
- type: outputs[key].type,
- }
- })
+ res.vars = outputs
+ ? Object.keys(outputs).map((key) => {
+ return {
+ variable: key,
+ type: outputs[key].type,
+ }
+ })
+ : []
break
}