瀏覽代碼

fix: undefined match the wrong output schema (#25971)

tags/1.9.0
Joel 1 月之前
父節點
當前提交
1550316b8d
沒有連結到貢獻者的電子郵件帳戶。
共有 1 個檔案被更改,包括 1 行新增1 行删除
  1. 1
    1
      web/app/components/workflow/nodes/_base/components/variable/use-match-schema-type.ts

+ 1
- 1
web/app/components/workflow/nodes/_base/components/variable/use-match-schema-type.ts 查看文件

@@ -4,7 +4,7 @@ import type { AnyObj } from './match-schema-type'
import matchTheSchemaType from './match-schema-type'

export const getMatchedSchemaType = (obj: AnyObj, schemaTypeDefinitions?: SchemaTypeDefinition[]): string => {
if(!schemaTypeDefinitions) return ''
if(!schemaTypeDefinitions || obj === undefined || obj === null) return ''
const matched = schemaTypeDefinitions.find(def => matchTheSchemaType(obj, def.schema))
return matched ? matched.name : ''
}

Loading…
取消
儲存