diff options
author | David RodrÃguez <deivid.rodriguez@riseup.net> | 2021-10-01 16:16:32 +0200 |
---|---|---|
committer | git <svn-admin@ruby-lang.org> | 2021-10-10 23:12:28 +0900 |
commit | 6c878731c1b0de974e071d532e7708e1a1ce9d71 (patch) | |
tree | 8016bfe881825f29da74321cbe17bd836b9f5243 | |
parent | 05e3d7b9674c1008af85ad9f177d18ebf8d699b1 (diff) |
[ruby/rubygems] Remove redundant `File.expand_path`
`File.realpath` already expands paths.
https://github.com/rubygems/rubygems/commit/25524ebbeb
-rw-r--r-- | lib/rubygems/package.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/rubygems/package.rb b/lib/rubygems/package.rb index 6c6278f483..10d9b85bf3 100644 --- a/lib/rubygems/package.rb +++ b/lib/rubygems/package.rb @@ -467,7 +467,7 @@ EOM raise Gem::Package::PathError.new(filename, destination_dir) if filename.start_with? '/' - destination_dir = File.expand_path(File.realpath(destination_dir)) + destination_dir = File.realpath(destination_dir) destination = File.expand_path(filename, destination_dir) raise Gem::Package::PathError.new(destination, destination_dir) unless |