diff options
author | francis <francis> | 2009-04-08 05:34:51 +0000 |
---|---|---|
committer | francis <francis> | 2009-04-08 05:34:51 +0000 |
commit | 2424bdf7da5346a6bf28dbaf9ff4d9bfd70b070c (patch) | |
tree | 80e1bc7adb4bf633ecd093357531f36fc199ba88 /app/helpers/link_to_helper.rb | |
parent | 14b2c6e814484a76e52cc8108fa8bdf8081606cc (diff) |
Remove some uses of gsub!, which might be clobbering other versions of strings
which are really members of some other class
Diffstat (limited to 'app/helpers/link_to_helper.rb')
-rw-r--r-- | app/helpers/link_to_helper.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/helpers/link_to_helper.rb b/app/helpers/link_to_helper.rb index 8fdb092ae..9c0713435 100644 --- a/app/helpers/link_to_helper.rb +++ b/app/helpers/link_to_helper.rb @@ -5,7 +5,7 @@ # Copyright (c) 2007 UK Citizens Online Democracy. All rights reserved. # Email: francis@mysociety.org; WWW: http://www.mysociety.org/ # -# $Id: link_to_helper.rb,v 1.51 2009-04-03 14:07:46 louise Exp $ +# $Id: link_to_helper.rb,v 1.52 2009-04-08 05:34:51 francis Exp $ module LinkToHelper @@ -145,7 +145,7 @@ module LinkToHelper # and also 3.3 of http://www.ietf.org/rfc/rfc2396.txt # It turns out this is a regression in Rails 2.1, caused by this bug fix: # http://rails.lighthouseapp.com/projects/8994/tickets/144-patch-bug-in-rails-route-globbing - url.gsub!("%2F", "/") + url = url.gsub("%2F", "/") if !postfix.nil? && !postfix.empty? url = url + "/" + postfix |