fix: When chatflow's file uploads changed from not being supported to… (#14341)

Co-authored-by: 刘江波 <jiangbo721@163.com>
This commit is contained in:
jiangbo721 2025-03-03 17:41:28 +08:00 committed by GitHub
parent 972421efe2
commit 829cd70889
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -180,7 +180,7 @@ class Workflow(Base):
features["file_upload"]["enabled"] = image_enabled
features["file_upload"]["number_limits"] = image_number_limits
features["file_upload"]["allowed_file_upload_methods"] = image_transfer_methods
features["file_upload"]["allowed_file_types"] = ["image"]
features["file_upload"]["allowed_file_types"] = features["file_upload"].get("allowed_file_types", ["image"])
features["file_upload"]["allowed_file_extensions"] = []
del features["file_upload"]["image"]
self._features = json.dumps(features)