Fix: return default path with nonexistent home dir

This commit is contained in:
Pavel Valena 2018-07-18 18:33:31 +02:00
parent 32488add5b
commit 5bf57b1504
1 changed files with 1 additions and 0 deletions

View File

@ -119,6 +119,7 @@ module Gem
def default_path def default_path
path = default_dirs.collect {|location, paths| paths[:gem_dir]} path = default_dirs.collect {|location, paths| paths[:gem_dir]}
path.unshift Gem.user_dir if File.exist? Gem.user_home path.unshift Gem.user_dir if File.exist? Gem.user_home
path
end end
def default_ext_dir_for base_dir def default_ext_dir_for base_dir