title: Rails ignores collection route and routes to show action instead
body: <p>I have the following routes:</p>
  
  <pre><code>resources :transactions do
    collection do
      post :detail
    end
  end
  </code></pre>
  
  <p>When I got to <a href="http://localhost:3000/transactions/detail" rel="nofollow">http://localhost:3000/transactions/detail</a>, rails gives me this error: </p>
  
  <p><strong>ActiveRecord::RecordNotFound in TransactionsController#show</strong></p>
  
  <p><em>Couldn't find Transaction with id=detail</em></p>
  
  <p>This makes me think the show route is taking precedence over my collection route, but I can't figure out why. Very similar to this issue: <a href="https://stackoverflow.com/questions/3099466/rails-ignores-collection-route-and-goes-with-show-action-instead">Rails ignores collection route and goes with show action instead</a>, but I don't have a duplicate resources :transactions entry.</p>