diff options
-rw-r--r-- | lib/rubygems/spec_fetcher.rb | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -181,7 +181,7 @@ class Gem::SpecFetcher min_length = gem_name.length - max max_length = gem_name.length + max - matches = names.map do |n| len = n.name.length # If the length is min_length or shorter, we've done `max` deletions. # If the length is max_length or longer, we've done `max` insertions. @@ -206,7 +206,7 @@ class Gem::SpecFetcher # If all else fails, return the name and the calculated distance. [n.name, distance] - end.compact matches = if matches.empty? && type != :prerelease suggest_gems_from_name gem_name, :prerelease |