summaryrefslogtreecommitdiff
path: root/lib/bundler/source/rubygems.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/bundler/source/rubygems.rb')
-rw-r--r--lib/bundler/source/rubygems.rb4
1 files changed, 1 insertions, 3 deletions
diff --git a/lib/bundler/source/rubygems.rb b/lib/bundler/source/rubygems.rb
index 925bec6662..0112e2be15 100644
--- a/lib/bundler/source/rubygems.rb
+++ b/lib/bundler/source/rubygems.rb
@@ -145,9 +145,7 @@ module Bundler
spec.loaded_from = loaded_from(spec)
["Installing #{version_message(spec)}", spec.post_install_message]
ensure
- if install_path && Bundler.requires_sudo?
- FileUtils.remove_entry_secure(install_path)
- end
+ Bundler.rm_rf(install_path) if Bundler.requires_sudo?
end
def cache(spec, custom_path = nil)