Make active storage blobs cacheable

This commit is contained in:
Kevin McConnell
2025-01-28 11:45:33 +00:00
parent c213914af6
commit ed17bc28ab
+5
View File
@@ -0,0 +1,5 @@
ActiveSupport.on_load(:active_storage_blob) do
ActiveStorage::DiskController.after_action only: :show do
response.set_header("Cache-Control", "max-age=3600, public")
end
end