diff options
author | Douwe Maan <douwe@gitlab.com> | 2016-01-13 14:21:32 +0000 |
---|---|---|
committer | Douwe Maan <douwe@gitlab.com> | 2016-01-13 14:21:32 +0000 |
commit | c7d9e7806a2cfb887533e1fab24a8340988272d4 (patch) | |
tree | 034957f410724ac5c12a17b05694bfd3b2b16f5a /config | |
parent | 9664424cab50ea2ac11669dc73c26f029e229fb9 (diff) | |
parent | 710659fc1fe73e4feffdb3fbb14f4098bb58046c (diff) | |
download | gitlab-ce-c7d9e7806a2cfb887533e1fab24a8340988272d4.tar.gz |
Merge branch 'fix/reference_filter_uri_decode_error_for_master' into 'master'
Fix #9963 reference_filter "Encoding::CompatibilityError" bug with some complex URL;
https://github.com/gitlabhq/gitlabhq/pull/9964
@DouweM
See merge request !2383
Diffstat (limited to 'config')
-rw-r--r-- | config/initializers/1_settings.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/config/initializers/1_settings.rb b/config/initializers/1_settings.rb index a9c5b2caf0a..d625a909bf1 100644 --- a/config/initializers/1_settings.rb +++ b/config/initializers/1_settings.rb @@ -11,7 +11,7 @@ class Settings < Settingslogic # get host without www, thanks to http://stackoverflow.com/a/6674363/1233435 def get_host_without_www(url) - url = URI.encode(url) + url = CGI.escape(url) uri = URI.parse(url) uri = URI.parse("http://#{url}") if uri.scheme.nil? host = uri.host.downcase |