summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSamuel E. Giddins <segiddins@segiddins.me>2015-05-16 18:44:17 -0700
committerAndre Arko <andre@arko.net>2015-05-17 20:35:15 -0700
commit177d4c12967cd385f381dc0584489ff74a654ad3 (patch)
tree20310c150f0a4338bc45d0da04d687693dd06e1e
parentc7c13d06f031df1c50c41e577b0c3a8166539816 (diff)
downloadbundler-177d4c12967cd385f381dc0584489ff74a654ad3.tar.gz
[RubyGemsIntegration] Mark loaded specs as activated
-rw-r--r--lib/bundler/rubygems_integration.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/bundler/rubygems_integration.rb b/lib/bundler/rubygems_integration.rb
index 3bb4cc24a9..5f2562af4b 100644
--- a/lib/bundler/rubygems_integration.rb
+++ b/lib/bundler/rubygems_integration.rb
@@ -39,6 +39,11 @@ module Bundler
end
def mark_loaded(spec)
+ if spec.respond_to?(:activated=)
+ current = Gem.loaded_specs[spec.name]
+ current.activated = false if current
+ spec.activated = true
+ end
Gem.loaded_specs[spec.name] = spec
end