Skip to content

Fix REST API digital object downloads#2354

Open
sevein wants to merge 1 commit into
qa/2.xfrom
dev/sendfile-fix
Open

Fix REST API digital object downloads#2354
sevein wants to merge 1 commit into
qa/2.xfrom
dev/sendfile-fix

Conversation

@sevein
Copy link
Copy Markdown
Member

@sevein sevein commented May 15, 2026

Return the digital object download marker from the action and stream the file contents directly. The previous code passed readfile() into setContent(), which mixed immediate output with Symfony response content handling and stored the byte count returned by readfile() as response content.

Mark the Symfony response as header-only after readfile() so the final rendering filter does not send response content after the file body has already been emitted.

Return the digital object download marker from the action and stream the file
contents directly. The previous code passed readfile() into setContent(),
which mixed immediate output with Symfony response content handling and stored
the byte count returned by readfile() as response content.

Mark the Symfony response as header-only after readfile() so the final
rendering filter does not send response content after the file body has already
been emitted.
@sevein sevein requested a review from a team May 15, 2026 14:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant