diff --git a/web/app/components/plugins/marketplace/types.ts b/web/app/components/plugins/marketplace/types.ts index dd5df48ed0..a806a00f85 100644 --- a/web/app/components/plugins/marketplace/types.ts +++ b/web/app/components/plugins/marketplace/types.ts @@ -74,6 +74,7 @@ export type TemplateCollection = { export type Template = { id: string index_id: string + version?: string template_name: string icon: string icon_background?: string diff --git a/web/utils/template.ts b/web/utils/template.ts index bf864c7b6b..f041d6c150 100644 --- a/web/utils/template.ts +++ b/web/utils/template.ts @@ -9,7 +9,6 @@ type GraphPayload = { } type DslPayload = { - version?: string | number workflow?: { graph?: GraphPayload } @@ -43,21 +42,6 @@ export const parseGraphFromDsl = (dslContent: string): ParsedGraph => { } } -export const parseDslVersionFromDsl = (dslContent: string): string | null => { - if (!dslContent) - return null - - try { - const data = yamlLoad(dslContent) as DslPayload - if (data?.version === undefined || data?.version === null) - return null - return String(data.version) - } - catch { - return null - } -} - type UsedCountFormatOptions = { precision?: number rounding?: 'round' | 'floor'