Method: Cloudinary::Utils.resource_type_for_format

Defined in:
lib/cloudinary/utils.rb

.resource_type_for_format(format) ⇒ Object



996
997
998
999
1000
1001
1002
1003
1004
1005
# File 'lib/cloudinary/utils.rb', line 996

def self.resource_type_for_format(format)
  case
  when self.supported_format?(format, IMAGE_FORMATS)
    'image'
  when self.supported_format?(format, VIDEO_FORMATS), self.supported_format?(format, AUDIO_FORMATS)
    'video'
  else
    'raw'
  end
end