title: Rails 3 link_to routes (edit) nested resources
body: <p>Sorry if this has been asked elsewhere, but I can't figure this out. I have a forum with sections, topics, and replies. I'm trying to edit and delete replies from the show topic view. This is the structure:</p>
  
  <pre><code>resources :sections do
    resources :topics do
      resources :replies
    end
  end
  </code></pre>
  
  <p>So I do a rake routes to see where I'm linking my edit reply. I see that its edit_section_topic_reply and in my link_to I add _path to it. Now this is what I can't figure out. What parameters am I passing it? Shouldn't it be:</p>
  
  <pre><code>&lt;%= link_to 'Edit', edit_section_topic_reply_path(@reply, @topic, @section) %&gt;
  </code></pre>
  
  <p>I get a <code>ActionController::RoutingError</code> in <code>Topics#show</code> when I do this.</p>
  
  <pre><code>No route matches {:topic_id=&gt;#&lt;Topic id: 2, section_id: 2, user_id: nil, subject: "subject", body: "body", created_at: "2011-03-04 08:37:37", updated_at: "2011-03-04 21:37:16"&gt;, :controller=&gt;"replies", :action=&gt;"edit", :section_id=&gt;nil, :id=&gt;#&lt;Section id: 2, name: "Section", description: "Section Description", created_at: "2011-03-04 07:50:56", updated_at: "2011-03-04 07:50:56"&gt;}
  </code></pre>
  
  <p>It seems like it isn't passing IDs, but the nest before, my new topic works fine </p>
  
  <pre><code>new_section_topic_reply_path(@topic, @section)
  </code></pre>