summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/bundler/rubygems_ext.rb12
1 files changed, 8 insertions, 4 deletions
diff --git a/lib/bundler/rubygems_ext.rb b/lib/bundler/rubygems_ext.rb
index f07debeef4..a85d55dca7 100644
--- a/lib/bundler/rubygems_ext.rb
+++ b/lib/bundler/rubygems_ext.rb
@@ -81,12 +81,16 @@ module Gem
attr_accessor :remote, :relative_loaded_from
- remove_method :source
- attr_writer :source
- def source
- (defined?(@source) && @source) || Gem::Source::Installed.new
+ module AllowSettingSource
+ attr_writer :source
+
+ def source
+ (defined?(@source) && @source) || super
+ end
end
+ prepend AllowSettingSource
+
alias_method :rg_full_gem_path, :full_gem_path
alias_method :rg_loaded_from, :loaded_from