diff options
Diffstat (limited to 'app/controllers/application.rb')
-rw-r--r-- | app/controllers/application.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/app/controllers/application.rb b/app/controllers/application.rb index 795c50d4b..238239c44 100644 --- a/app/controllers/application.rb +++ b/app/controllers/application.rb @@ -16,6 +16,7 @@ # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. require 'uri' +require 'cgi' class ApplicationController < ActionController::Base layout 'base' @@ -123,7 +124,7 @@ class ApplicationController < ActionController::Base end def redirect_back_or_default(default) - back_url = params[:back_url] + back_url = CGI.unescape(params[:back_url].to_s) if !back_url.blank? uri = URI.parse(back_url) # do not redirect user to another host |