Paperclip console command for Rails 4

I want to upload paperclip files in console mode. In rails 3, I tried this and it worked. =>,

However, in Rails4, when I try this, I get

ActiveRecord::UnknownAttributeError: unknown attribute: your_paperclip_field

I am using the master branch of paperclip.

My guess would be, because of strong_params in Rails 4. You need to add

  def paperclip_model_parameters