mirror of
https://github.com/sst/opencode.git
synced 2025-12-23 10:11:41 +00:00
fix: read when file is svg
This commit is contained in:
parent
75a9c42789
commit
84a0868e66
1 changed files with 1 additions and 1 deletions
|
|
@ -93,7 +93,7 @@ export const ReadTool = Tool.define("read", {
|
|||
throw new Error(`File not found: ${filepath}`)
|
||||
}
|
||||
|
||||
const isImage = file.type.startsWith("image/")
|
||||
const isImage = file.type.startsWith("image/") && file.type !== "image/svg+xml"
|
||||
const isPdf = file.type === "application/pdf"
|
||||
if (isImage || isPdf) {
|
||||
const mime = file.type
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue