title: 'Unknown attribute' error in controller
body: <p>I want to make my own simple authentication.
  So I made User model and Users controller. And I have a form for sign up
  Part of my Users controller.</p>
  
  <pre><code>  def create
      @user = User.new(user_params)
      if @user.save
        redirect_to root_path, notice: "You've successfully singed up."
      else
        render 'new'
      end
    end
  
    private
  
    def user_params
      params.require(:user).permit(:username, :password, :password_confirmation)
    end
  </code></pre>
  
  <p>And error:</p>
  
  <blockquote>
    <p>unknown attribute: password</p>
  </blockquote>
  
  <p>In my Users table I have <code>username</code> and <code>password_digest</code> for each User. So there're not column like <code>password</code>.</p>
  
  <p>I've just watched Rails Cast episode but it is about Rails 3 and author uses <code>attr_accessible</code> but I've read in Rails 4 we should use strong parameters.</p>
  
  <p>How I can deal with it?</p>