Class: Decidim::RecordImageUploader

Inherits:
ImageUploader show all
Defined in:
app/uploaders/decidim/record_image_uploader.rb

Overview

This class deals with uploading record specific images that have more limited content types than the defaults.

Instance Method Summary collapse

Methods inherited from ImageUploader

#dimensions_info, #max_image_height_or_width, #strip, #validate_dimensions, #validate_size

Methods inherited from ApplicationUploader

#downloader, #manipulate!, #provider, #store_dir

Instance Method Details

#content_type_allowlistObject



7
8
9
# File 'app/uploaders/decidim/record_image_uploader.rb', line 7

def content_type_allowlist
  %w(image/jpeg image/png)
end

#extension_allowlistObject



11
12
13
# File 'app/uploaders/decidim/record_image_uploader.rb', line 11

def extension_allowlist
  %w(jpeg jpg png)
end