Andrew Bloom
2009-Mar-05 17:52 UTC
[PATCH] Routes are improperly generated with a blank :path_prefix
Please see my write up here:
http://www.somethingunimportant.com/2009/03/04/get-my-patch-added-to-core/
And my ticket/patch here:
http://rails.lighthouseapp.com/projects/8994-ruby-on-rails/tickets/2122-routing-with-a-blank-path_prefix-causes-a-bad-url-to-generate#ticket-2122-3
Brief description:
When generating routes, a nil :path_prefix is ignored, but a
blank :path_prefix ("") is treated like a string with content. In this
situation, when the strings are joined an extra slash is added to the
beginning of the path.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Core" group.
To post to this group, send email to rubyonrails-core@googlegroups.com
To unsubscribe from this group, send email to
rubyonrails-core+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/rubyonrails-core?hl=en
-~----------~----~----~----~------~----~------~--~---
Andrew Bloom
2009-Mar-05 17:54 UTC
Re: Routes are improperly generated with a blank :path_prefix
Sent to quickly... This patch fixes the situation where the :path_prefix is a blank string, and simply ignores it as if it were nil. On Mar 5, 11:52 am, Andrew Bloom <akbl...@gmail.com> wrote:> Please see my write up here:http://www.somethingunimportant.com/2009/03/04/get-my-patch-added-to-... > And my ticket/patch here:http://rails.lighthouseapp.com/projects/8994-ruby-on-rails/tickets/21... > > Brief description: > When generating routes, a nil :path_prefix is ignored, but a > blank :path_prefix ("") is treated like a string with content. In this > situation, when the strings are joined an extra slash is added to the > beginning of the path.--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@googlegroups.com To unsubscribe from this group, send email to rubyonrails-core+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en -~----------~----~----~----~------~----~------~--~---