Skip to content
This repository has been archived by the owner on Jul 13, 2023. It is now read-only.

Add custom extension to a file type #1601

Closed
tomraulet opened this issue Jul 16, 2014 · 3 comments
Closed

Add custom extension to a file type #1601

tomraulet opened this issue Jul 16, 2014 · 3 comments

Comments

@tomraulet
Copy link

I want to attach file with .fasta extension which has a plain/text content type.

Content type validators throws :
Content Type Spoof: Filename file.fasta ([]), content type discovered from file command: text/plain. See documentation to allow this combination.

Validation from my model :
validates_attachment :fasta_file, :content_type => { :content_type => 'text/plain' }

So I would like to associate custom file extension to content type (fasta -> plain/text)

PS : uploading file.txt (with same content) works fine.

@maclover7
Copy link
Contributor

Is this fixed with #1839 ?

@tute
Copy link
Contributor

tute commented May 15, 2015

ping @foxpowa. Is this now fixed?

@tomraulet
Copy link
Author

I'm not able to test easily, I'm not using paperclip anymore, sorry guys.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants