title: Rails 3: CanCan stuck on a redirect loop!
body: <p>I'm upgrading my rails 2.3.8 app to Rails 3. </p>
  
  <p>I'm using cancan for authorization which seems to be working for most of my actions apart from the root. </p>
  
  <p>The way I have cancan is setup is that when a user is not authorized, he is redirected to the root url of the app (and displayed a short message). </p>
  
  <p>You don't need to be logged in to view the root action yet cancan keeps trying to redirect to it - so it's stuck on a redirection loop. </p>
  
  <p>This all worked in rails 2.3.8 so it makes me suspect one of two things: </p>
  
  <ol>
  <li>The new version of cancan works differently</li>
  <li>I've made a mistake in setting up routes</li>
  </ol>
  
  <p>This is the root action / controller in routes.rb: </p>
  
  <pre><code>root :to =&gt; 'tours#browse_tours'
  </code></pre>
  
  <p>And this is what I've specified in cancan's ability.rb model (for non-logged in users):</p>
  
  <pre><code>can :browse_tours, Tour
  </code></pre>
  
  <p>Any thoughts?</p>