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: system file upload can't export custom file types (#20122)

非法操作9b1dc1de7aee
diff --git a/api/models/workflow.py b/api/models/workflow.py
index 64b0e165779..b0cb8dccd99 100644
--- a/api/models/workflow.py
+++ b/api/models/workflow.py
@@ -199,7 +199,9 @@ class Workflow(Base):
features["file_upload"]["number_limits"] = image_number_limits
features["file_upload"]["allowed_file_upload_methods"] = image_transfer_methods
features["file_upload"]["allowed_file_types"] = features["file_upload"].get("allowed_file_types", ["image"])
- features["file_upload"]["allowed_file_extensions"] = []
+ features["file_upload"]["allowed_file_extensions"] = features["file_upload"].get(
+ "allowed_file_extensions", []
+ )
del features["file_upload"]["image"]
self._features = json.dumps(features)
return self._features