Skip to content

Commit

Permalink
fixup! Alternative time zone lookup using strftime, to complement Rai…
Browse files Browse the repository at this point in the history
…ls mapping
  • Loading branch information
epologee committed Apr 28, 2022
1 parent f72cf4d commit 7409e6f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/ice_cube/parsers/ical_parser.rb
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ def self.find_zone(tzid)
begin
Time.find_zone!(zone) if zone.present?
rescue ArgumentError
(rails_zone, tzinfo_id) = ActiveSupport::TimeZone::MAPPING.find do |(k, _)|
(rails_zone, _tzinfo_id) = ActiveSupport::TimeZone::MAPPING.find do |(k, _)|
candidate = Time.find_zone!(k)
candidate.now.strftime("%Z") == zone
end
Expand Down

0 comments on commit 7409e6f

Please sign in to comment.