aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport
diff options
context:
space:
mode:
authorXavier Noria <fxn@hashref.com>2017-07-16 17:55:58 +0200
committerXavier Noria <fxn@hashref.com>2017-07-16 17:55:58 +0200
commit83f39a3bcf3f50d12d41bff4a110c57e2e4be605 (patch)
tree58638b7667e2c998066a7002c4437e692eaa75ee /activesupport
parent8f6bd6fa6f165f5a069f0cf6844cf2278d97ea6e (diff)
downloadrails-83f39a3bcf3f50d12d41bff4a110c57e2e4be605.tar.gz
rails-83f39a3bcf3f50d12d41bff4a110c57e2e4be605.tar.bz2
rails-83f39a3bcf3f50d12d41bff4a110c57e2e4be605.zip
explain why require_relative is not used here [ci skip]
Diffstat (limited to 'activesupport')
-rw-r--r--activesupport/lib/active_support/cache.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/activesupport/lib/active_support/cache.rb b/activesupport/lib/active_support/cache.rb
index e9ed60398b..49d8965cb1 100644
--- a/activesupport/lib/active_support/cache.rb
+++ b/activesupport/lib/active_support/cache.rb
@@ -101,6 +101,8 @@ module ActiveSupport
# Obtains the specified cache store class, given the name of the +store+.
# Raises an error when the store class cannot be found.
def retrieve_store_class(store)
+ # require_relative cannot be used here because the class might be
+ # provided by another gem, like redis-activesupport for example.
require "active_support/cache/#{store}"
rescue LoadError => e
raise "Could not find cache store adapter for #{store} (#{e})"