mirror of
https://github.com/open-webui/open-webui.git
synced 2026-07-16 23:21:44 -05:00
[PR #22431] [CLOSED] fix: change file.content to file.data #49736
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/open-webui/open-webui/pull/22431
Author: @gambletan
Created: 3/8/2026
Status: ❌ Closed
Base:
dev← Head:fix/file-content-to-data📝 Commits (2)
205b3bcfix: remove incorrect public-read grant from note write_access check26d27dcfix: change file.content to file.data in get_file_content_by_id📊 Changes
3 files changed (+35 additions, -2 deletions)
View changed files
➕
PR_BODY.md(+34 -0)📝
backend/open_webui/routers/files.py(+1 -1)📝
backend/open_webui/routers/notes.py(+0 -1)📄 Description
Description
files.py, the code referencedfile.content.get("content", "")but theFileModelobject has nocontentattribute — the correct attribute isfile.data. This caused anAttributeErrorwhen attempting to access file content.Fixed
file.contenttofile.dataso the file content is correctly retrieved from the model'sdataattribute.Additional Information
Contributor License Agreement
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.