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: code lint (#24563)

jiangbo72166e80f9dacb7
diff --git a/api/core/tools/tool_engine.py b/api/core/tools/tool_engine.py
index 10db4d95032..c3fdc373033 100644
--- a/api/core/tools/tool_engine.py
+++ b/api/core/tools/tool_engine.py
@@ -280,7 +280,7 @@ class ToolEngine:
mimetype = "image/jpeg"
yield ToolInvokeMessageBinary(
- mimetype=response.meta.get("mime_type", "image/jpeg"),
+ mimetype=response.meta.get("mime_type", mimetype),
url=cast(ToolInvokeMessage.TextMessage, response.message).text,
)
elif response.type == ToolInvokeMessage.MessageType.BLOB: