deprecated_mass_assignment_security.rb:17:in `attr_accessible': `attr_accessible` is extracted out of Rails into a gem. Please use new recommended protection model for params(strong_parameters) or add `protected_attributes` to your Gemfile to use old one. (RuntimeError)
我尝试了消息所说的内容,将gem“strong_parameters”添加到我的Gemfile中.
但是当我做rails时,我得到了上面的错误.
更新
我试过了:
config.active_record.whitelist_attributes = true
在confgi / application.rb中,也是假的,但实际上我不明白那个选项.