mirror of
https://github.com/langgenius/dify.git
synced 2026-04-22 11:47:40 +08:00
fix(skill): return raw content as fallback for non-JSON file content
When file content is not in JSON format (e.g., newly uploaded files), return the raw content instead of empty string to ensure files display correctly.
This commit is contained in:
@ -106,9 +106,7 @@ export const useGetAppAssetFileContent = (appId: string, nodeId: string) => {
|
||||
return result
|
||||
}
|
||||
catch {
|
||||
return {
|
||||
content: '',
|
||||
}
|
||||
return { content: data.content }
|
||||
}
|
||||
},
|
||||
enabled: !!appId && !!nodeId,
|
||||
|
||||
Reference in New Issue
Block a user