instance method show

Ruby on Rails 7.2.3

Since v6.1.7.10

Available in: v6.1.7.10 v7.0.10 v7.1.6 v7.2.3 v8.0.4 v8.1.2

Signature

show()

No documentation comment.

Source
# File activestorage/app/controllers/active_storage/blobs/proxy_controller.rb, line 14
  def show
    if request.headers["Range"].present?
      send_blob_byte_range_data @blob, request.headers["Range"]
    else
      http_cache_forever public: true do
        response.headers["Accept-Ranges"] = "bytes"
        response.headers["Content-Length"] = @blob.byte_size.to_s

        send_blob_stream @blob, disposition: params[:disposition]
      end
    end
  end

Defined in activestorage/app/controllers/active_storage/blobs/proxy_controller.rb line 14 · View on GitHub · Improve this page · Find usages on GitHub

Defined in ActiveStorage::Blobs::ProxyController

Type at least 2 characters to search.

↑↓ navigate · open · esc close