This project is archived and is in readonly mode.

#5306 ✓resolved
fabrik42

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

Reported by fabrik42 | August 5th, 2010 @ 11:08 AM | in 3.0.2

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

Comments and changes to this ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>

Attachments

Referenced by

Pages