소스 검색

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

tags/1.9.0
Joel 1 개월 전
부모
커밋
1550316b8d
No account linked to committer's email address
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…
취소
저장