From d02844f2499be488d262bc274530ec44e242fd70 Mon Sep 17 00:00:00 2001 From: Koichi ITO Date: Sat, 12 Aug 2017 21:32:15 +0900 Subject: Use frozen string literal in Active Storage --- activestorage/app/controllers/active_storage/blobs_controller.rb | 2 ++ .../app/controllers/active_storage/direct_uploads_controller.rb | 2 ++ activestorage/app/controllers/active_storage/disk_controller.rb | 2 ++ activestorage/app/controllers/active_storage/variants_controller.rb | 2 ++ 4 files changed, 8 insertions(+) (limited to 'activestorage/app/controllers') diff --git a/activestorage/app/controllers/active_storage/blobs_controller.rb b/activestorage/app/controllers/active_storage/blobs_controller.rb index cff88bd488..00aa8567c8 100644 --- a/activestorage/app/controllers/active_storage/blobs_controller.rb +++ b/activestorage/app/controllers/active_storage/blobs_controller.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + # Take a signed permanent reference for a blob and turn it into an expiring service URL for download. # Note: These URLs are publicly accessible. If you need to enforce access protection beyond the # security-through-obscurity factor of the signed blob references, you'll need to implement your own diff --git a/activestorage/app/controllers/active_storage/direct_uploads_controller.rb b/activestorage/app/controllers/active_storage/direct_uploads_controller.rb index 0d93985897..205d173648 100644 --- a/activestorage/app/controllers/active_storage/direct_uploads_controller.rb +++ b/activestorage/app/controllers/active_storage/direct_uploads_controller.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + # Creates a new blob on the server side in anticipation of a direct-to-service upload from the client side. # When the client-side upload is completed, the signed_blob_id can be submitted as part of the form to reference # the blob that was created up front. diff --git a/activestorage/app/controllers/active_storage/disk_controller.rb b/activestorage/app/controllers/active_storage/disk_controller.rb index 76377a0f20..b10d4e2cac 100644 --- a/activestorage/app/controllers/active_storage/disk_controller.rb +++ b/activestorage/app/controllers/active_storage/disk_controller.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + # Serves files stored with the disk service in the same way that the cloud services do. # This means using expiring, signed URLs that are meant for immediate access, not permanent linking. # Always go through the BlobsController, or your own authenticated controller, rather than directly diff --git a/activestorage/app/controllers/active_storage/variants_controller.rb b/activestorage/app/controllers/active_storage/variants_controller.rb index b72b0ff7f5..02e3010626 100644 --- a/activestorage/app/controllers/active_storage/variants_controller.rb +++ b/activestorage/app/controllers/active_storage/variants_controller.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + # Take a signed permanent reference for a variant and turn it into an expiring service URL for download. # Note: These URLs are publicly accessible. If you need to enforce access protection beyond the # security-through-obscurity factor of the signed blob and variation reference, you'll need to implement your own -- cgit v1.2.3