class method
self.find_tzinfo
Ruby on Rails 2.3.18
Since v2.3.18Signature
self.find_tzinfo(name)
TODO: Preload instead of lazy load for thread safety
Parameters
-
namereq
Source
# File activesupport/lib/active_support/values/time_zone.rb, line 297
def self.find_tzinfo(name)
require 'tzinfo' unless defined?(TZInfo)
::TZInfo::Timezone.get(MAPPING[name] || name)
rescue TZInfo::InvalidTimezoneIdentifier
nil
end
Defined in activesupport/lib/active_support/values/time_zone.rb line 297
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActiveSupport::TimeZone