Acts as attachement

undefined method `content_type' for "image.jpg":String

Make sure you have :multipart => true set correctly in the form tag.
It's trying to call params[:uploaded_data].content_type