1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
rails--rails/activestorage/lib/active_storage
Alex Ghiculescu 550d728bd1 Active Storage: incorrect defaults
https://github.com/rails/rails/pull/42225 identified that some of the content types used as defaults by Active Storage aren't recognized by `mini_mime`. This means that in practice code like [this](https://github.com/rails/rails/pull/42225/files#diff-7a3ec24c556b138abdbd67066ab5125b73528e45891d83142e417d3944194128R116) will crash or not function correctly. In [this](https://github.com/rails/rails/pull/42225/files#diff-c2010824d2d2e8d841ff4fc058c264c12d870e893025b153e6de571fba6b6c6cR194) example, a file with content_type `image/jpg` is treated as a PNG by the representer, since `image/jpg` isn't a valid content type according to `mini_mime`.

I don't think the default content_types should include formats that have never actually worked, so I'm proposing we remove them from the defaults.
2021-09-22 16:38:52 -05:00
..
analyzer Instrument ActiveStorage analyzers 2021-08-17 16:55:05 +09:00
attached Standardize nodoc comments 2021-07-29 21:18:07 +00:00
previewer ActiveStorage: The parameters sent to ffmpeg for are now configurable 2021-06-16 14:15:34 +12:00
service Upgrade azure-storage-blob to use at least 2.0.0 2021-08-23 22:03:15 +02:00
transformers Standardize :doc: comments [ci skip] 2021-08-06 17:10:45 +09:00
analyzer.rb Merge branch 'instrument-analyzers' of https://github.com/shouichi/rails into shouichi-instrument-analyzers 2021-08-28 00:48:44 -07:00
attached.rb Fix ActiveStorage has_many_attached when record is not persisted 2021-06-12 19:49:21 +02:00
downloader.rb Standardize nodoc comments 2021-07-29 21:18:07 +00:00
engine.rb Active Storage: incorrect defaults 2021-09-22 16:38:52 -05:00
errors.rb Active Storage: raise PreviewError when a preview cannot be generated 2021-02-26 14:06:52 -05:00
fixture_set.rb Add docs on how to write tests for using Active Storage [ci skip] 2021-05-06 16:56:53 -05:00
gem_version.rb Preparing for 7.0.0.alpha2 release 2021-09-15 18:22:51 -04:00
log_subscriber.rb Mirror direct uploads 2019-05-22 15:07:35 -04:00
previewer.rb Standardize :doc: comments [ci skip] 2021-08-06 17:10:45 +09:00
reflection.rb Standardize nodoc comments 2021-07-29 21:18:07 +00:00
service.rb Standardize nodoc comments 2021-07-29 21:18:07 +00:00
version.rb Use frozen string literal in Active Storage 2017-08-12 21:43:42 +09:00