diff --git a/app/uploaders/picture_uploader.rb b/app/uploaders/picture_uploader.rb index 42856bd..670fd90 100644 --- a/app/uploaders/picture_uploader.rb +++ b/app/uploaders/picture_uploader.rb @@ -31,12 +31,10 @@ class PictureUploader < CarrierWave::Uploader::Base # process resize_to_fit: [50, 50] # end - # Add an allowlist of extensions which are allowed to be uploaded. - # For images you might use something like this: - # def extension_allowlist - # %w(jpg jpeg gif png) - # end - + def content_type_allowlist + /image\// + end + # Override the filename of the uploaded files: # Avoid using model.id or version_name here, see uploader/store.rb for details. # def filename