Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

This project is archived and is in readonly mode.

RESTful routes don't take symbol for the :path option anymore

#5306

Hi,

as I to rails 3 rc from beta4 I recognized the following problem:

When you declare a route like this:

MyRailsApp::Application.routes.draw do |map|
  resources :wiki_pages, :path => :pages do
    ..
  end
end
  • the rake routes task shows them correctly
  • link_to does generate just a link to "/"
  • navigation to /pages results in a ActionController::RoutingError

However, if you use a String instead of a Symbol to set the path, everything seems to work fine:

MyRailsApp::Application.routes.draw do |map|
  resources :wiki_pages, :path => 'pages' do
    ..
  end
end

Best,

Chris

Reported by fabrik42 · August 5th, 2010 @ 11:08 AM

State: resolved
Milestone: 3.0.2
Assigned to: José Valim José Valim
Importance: High