ruby on rails 4 - Paperclip fails to upload mp3 files -
i'm trying upload audio files website. however, paperclip unable upload mp3 files try upload. reason though able upload wav files. have found similar problems none of answers have worked me. advice appreciated.
audio.rb
has_attached_file :audio validates_attachment_content_type :audio, content_type: ['application/mp3','application/x-mp3', 'audio/mpeg', ['audio/mpeg'], 'audio/mp3'] validates_attachment_size :audio, :less_than => 35.megabytes
error
[paperclip] content type spoof: filename test.mp3 (binary/octet-stream headers, ["audio/mpeg"] extension), content type discovered file command: audio/mpeg. see documentation allow combination. [paperclip] content type spoof: filename test.mp3 (binary/octet-stream headers, ["audio/mpeg"] extension), content type discovered file command: audio/mpeg. see documentation allow combination. (0.1ms) rollback (0.1ms) rollback
Comments
Post a Comment