summaryrefslogtreecommitdiffstats
path: root/lib/redmine/scm
diff options
context:
space:
mode:
authorGo MAEDA <maeda@farend.jp>2020-01-23 23:28:34 +0000
committerGo MAEDA <maeda@farend.jp>2020-01-23 23:28:34 +0000
commit62fe933eed0cd542c978d3e77f5bfbb4d2031950 (patch)
treed38e3ddf0701c8162d85ef6be2158a3489c4e698 /lib/redmine/scm
parentba7d4745e2a6489ddd33cdc827a2a095ab97fcb7 (diff)
downloadredmine-62fe933eed0cd542c978d3e77f5bfbb4d2031950.tar.gz
redmine-62fe933eed0cd542c978d3e77f5bfbb4d2031950.zip
Ruby 2.7: Remove deprecated URI.escape/unescape (#32752).
Patch by Go MAEDA. git-svn-id: http://svn.redmine.org/redmine/trunk@19455 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'lib/redmine/scm')
-rw-r--r--lib/redmine/scm/adapters/subversion_adapter.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/redmine/scm/adapters/subversion_adapter.rb b/lib/redmine/scm/adapters/subversion_adapter.rb
index 09b4aacb5..8748641ce 100644
--- a/lib/redmine/scm/adapters/subversion_adapter.rb
+++ b/lib/redmine/scm/adapters/subversion_adapter.rb
@@ -108,7 +108,7 @@ module Redmine
next if entry['kind'] == 'dir' && commit_date.nil?
name = entry['name']['__content__']
- entries << Entry.new({:name => URI.unescape(name),
+ entries << Entry.new({:name => CGI.unescape(name),
:path => ((path.empty? ? "" : "#{path}/") + name),
:kind => entry['kind'],
:size => ((s = entry['size']) ? s['__content__'].to_i : nil),
@@ -289,7 +289,7 @@ module Redmine
def target(path = '')
base = /^\//.match?(path) ? root_url : url
uri = "#{base}/#{path}"
- uri = URI.escape(URI.escape(uri), '[]')
+ uri = Addressable::URI.encode(uri)
shell_quote(uri.gsub(/[?<>\*]/, ''))
end
end