Skip to content

Commit

Permalink
set Content-Disposition header for formats without player to serve th…
Browse files Browse the repository at this point in the history
…em as downloadable content (without breaking protected recordings) (#1084)
  • Loading branch information
Ithanil authored Jul 2, 2024
1 parent 2cdaa04 commit 0c54101
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions app/controllers/playback_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ def deliver_resource
resource_path = request.original_fullpath
static_resource_path = "/static-resource#{resource_path}"
response.headers['X-Accel-Redirect'] = static_resource_path
response.headers['Content-Disposition'] = "attachment" unless %w[presentation video screenshare].include?(@playback_format.format)
head(:ok)
end

Expand Down

0 comments on commit 0c54101

Please sign in to comment.