title: Rails: How to avoid this redirect loop?
body: <p>I'd like to force a user to change their password on login (assuming they've got a certain boolean marker set to true).</p>
  
  <p>Right now I'm trying to do it via a <code>before_filter</code> called <code>change_password_check</code> that's in <code>ApplicationController</code>. </p>
  
  <pre><code>def change_password_check
    if current_user.change_password == true
      flash[:notice] = "You must be update your password before continuing"
      redirect_to change_password_path
      return false
    end
  end
  </code></pre>
  
  <p>The problem, obviously, is that I get a redirect loop.</p>
  
  <p>So, how can I only do that <code>before_filter</code> if the user is NOT on the <code>change_password_check</code> route (or posting to <code>user#update</code>)?</p>
  
  <p>I'm running Rails 3.</p>