Fix deprecation and support Rails 4 protected_attributes