def image?(new_file)
      content_type = model.content_type || new_file.content_type
      content_type.to_s.start_with? "image"
    end
def image?(new_file)
      content_type = model.content_type || new_file.content_type
      content_type.to_s.start_with? "image"
    end
Checks if the file is an image based on the content type. We need this so
 we only create different versions of the file when it's an image.

 new_file - The uploaded file.

 Returns a Boolean.