aboutsummaryrefslogtreecommitdiffstats
path: root/activestorage/lib
diff options
context:
space:
mode:
authorGeorge Claghorn <george.claghorn@gmail.com>2018-08-06 22:23:47 -0400
committerGeorge Claghorn <george.claghorn@gmail.com>2018-08-06 22:23:47 -0400
commit79573b3afffafc070ec1eecf8c47678bbdae60c7 (patch)
treed2a41b4463b0251bc123a4a56c616d87a6605573 /activestorage/lib
parent1ed33a2a64f09182287c4bb283e574aad959126f (diff)
downloadrails-79573b3afffafc070ec1eecf8c47678bbdae60c7.tar.gz
rails-79573b3afffafc070ec1eecf8c47678bbdae60c7.tar.bz2
rails-79573b3afffafc070ec1eecf8c47678bbdae60c7.zip
Camelize instead of classifying
Avoid mangling service names that end in S: "GCS".classify # => "GC" "GCS".camelize # => "GCS"
Diffstat (limited to 'activestorage/lib')
-rw-r--r--activestorage/lib/active_storage/service/configurator.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activestorage/lib/active_storage/service/configurator.rb b/activestorage/lib/active_storage/service/configurator.rb
index 32fa9105c6..fa80c66c3b 100644
--- a/activestorage/lib/active_storage/service/configurator.rb
+++ b/activestorage/lib/active_storage/service/configurator.rb
@@ -26,7 +26,7 @@ module ActiveStorage
def resolve(class_name)
require "active_storage/service/#{class_name.to_s.underscore}_service"
- ActiveStorage::Service.const_get(:"#{class_name.classify}Service")
+ ActiveStorage::Service.const_get(:"#{class_name.camelize}Service")
rescue LoadError
raise "Missing service adapter for #{class_name.inspect}"
end