Creating versions with file_column but only if file is image

I would like to create versions of images uploaded to a model that has a
file_column but only if the file is a image.

file_column :file, :magick => { :versions => {“thumb” => “64x64”}}

If I upload a txt file this will give me an error of “File invalid

Any idears?

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs