method
instance_or_fallback
v8.1.1 -
Show latest stable
- Class:
ActiveSupport::Inflector::Inflections
instance_or_fallback(locale)public
No documentation available.
# File activesupport/lib/active_support/inflector/inflections.rb, line 83
def self.instance_or_fallback(locale)
return @__en_instance__ ||= new if locale == :en
I18n.fallbacks[locale].each do |k|
return @__instance__[k] if @__instance__.key?(k)
end
instance(locale)
end