summaryrefslogtreecommitdiff
path: root/lib/rubygems/core_ext
diff options
context:
space:
mode:
authorYuki Nishijima <yk.nishijima@gmail.com>2020-05-25 20:34:56 -0400
committerHiroshi SHIBATA <hsbt@ruby-lang.org>2020-06-05 07:32:42 +0900
commit77ba8a1d610114cdaf59993dceeb3ebf6f624436 (patch)
tree3f4774fc513a9d575d0ef23adb45b85c58e56564 /lib/rubygems/core_ext
parent5bbddba20b25cb2ddb7fbc82c355fb2f25633f73 (diff)
[rubygems/rubygems] Use LoadError#path to figure out the argument passed to 'require'
https://github.com/rubygems/rubygems/commit/5995394ec4
Notes
Notes: Merged: https://github.com/ruby/ruby/pull/3184
Diffstat (limited to 'lib/rubygems/core_ext')
-rw-r--r--lib/rubygems/core_ext/kernel_require.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/rubygems/core_ext/kernel_require.rb b/lib/rubygems/core_ext/kernel_require.rb
index 115ae0c..faf9886 100644
--- a/lib/rubygems/core_ext/kernel_require.rb
+++ b/lib/rubygems/core_ext/kernel_require.rb
@@ -148,7 +148,7 @@ module Kernel
RUBYGEMS_ACTIVATION_MONITOR.enter
begin
- if load_error.message.end_with?(path) and Gem.try_activate(path)
+ if load_error.path == path and Gem.try_activate(path)
require_again = true
end
ensure