1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Preserve old redirect URLs

They may be cached for existing apps upgrading to 6.1. Follows up on #34477.
This commit is contained in:
George Claghorn 2020-05-21 10:35:25 -04:00
parent abcbfe87e5
commit 7e52d0ae58

View file

@ -4,9 +4,11 @@ Rails.application.routes.draw do
scope ActiveStorage.routes_prefix do
get "/blobs/redirect/:signed_id/*filename" => "active_storage/blobs/redirect#show", as: :rails_service_blob
get "/blobs/proxy/:signed_id/*filename" => "active_storage/blobs/proxy#show", as: :rails_service_blob_proxy
get "/blobs/:signed_id/*filename" => "active_storage/blobs/redirect#show"
get "/representations/redirect/:signed_blob_id/:variation_key/*filename" => "active_storage/representations/redirect#show", as: :rails_blob_representation
get "/representations/proxy/:signed_blob_id/:variation_key/*filename" => "active_storage/representations/proxy#show", as: :rails_blob_representation_proxy
get "/representations/:signed_blob_id/:variation_key/*filename" => "active_storage/representations/redirect#show"
get "/disk/:encoded_key/*filename" => "active_storage/disk#show", as: :rails_disk_service
put "/disk/:encoded_token" => "active_storage/disk#update", as: :update_rails_disk_service