Permalink
Browse files

There is an "inherit" option on const_get too, why not use it?

  • Loading branch information...
1 parent 81f6bcb commit d0706c3626fcab9cd87a522071a3f6027a6fb79d @semaperepelitsa semaperepelitsa committed Jan 31, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 activesupport/lib/active_support/inflector/methods.rb
@@ -212,7 +212,7 @@ def constantize(camel_cased_word) #:nodoc:
constant = Object
names.each do |name|
- constant = constant.const_defined?(name, false) ? constant.const_get(name) : constant.const_missing(name)
+ constant = constant.const_get(name, false)
end
constant
end

0 comments on commit d0706c3

Please sign in to comment.