title: Devise with roles
body: <p>I am using devise for authentication, Now in registration steps i want to add extra parameter, so I use <code>devise_parameter_sanitizer</code> like following</p>
  
  <pre><code>def configure_permitted_parameters
    devise_parameter_sanitizer.permit(:sign_up, keys: [:first_name, :last_name, :email, :subdomain, :phone, :company, role_ids: []])
  end
  </code></pre>
  
  <p>If I pass <code>role_ids</code> rails will automatically add roles for user, but I want to pass <code>role_names</code> instead of <code>role_ids</code> but its give me error </p>
  
  <pre><code>ActiveModel::UnknownAttributeError (unknown attribute 'roles_name' for User.)
  </code></pre>
  
  <p><strong>Edited:</strong></p>
  
  <pre><code>models/user.rb
  has_many :roles_user, dependent: :destroy
  has_many :roles, through: :roles_user
  </code></pre>