diff options
author | Hiroshi SHIBATA <[email protected]> | 2023-03-22 13:17:33 +0900 |
---|---|---|
committer | Hiroshi SHIBATA <[email protected]> | 2023-03-23 17:18:49 +0900 |
commit | bec069b0cae3934bb2caee3aad7fbf587ab95937 () | |
tree | bf83ab29cfb9160c92c696b55cd1375e97e3f9de /lib/rubygems/basic_specification.rb | |
parent | 8a364b8512b84530cadfe9f27557fa0306ad9856 (diff) |
[rubygems/rubygems] util/rubocop -A --only Style/MultilineMemoization
https://.com/rubygems/rubygems/commit/c1f6e4a97b
Notes: Merged: https://.com/ruby/ruby/pull/7582
-rw-r--r-- | lib/rubygems/basic_specification.rb | 18 |
1 files changed, 7 insertions, 11 deletions
@@ -170,18 +170,14 @@ class Gem::BasicSpecification def to_fullpath(path) if activated? @paths_map ||= {} - @paths_map[path] ||= - begin - fullpath = nil - suffixes = Gem.suffixes - if suffixes.find do |suf| - full_require_paths.find do |dir| - File.file?(fullpath = "#{dir}/#{path}#{suf}") - end - end - fullpath - end end end end |