lib/edtf/humanize/season.rb in edtf-humanize-1.0.0 vs lib/edtf/humanize/season.rb in edtf-humanize-2.0.0

- old
+ new

@@ -1,25 +1,13 @@ +# frozen_string_literal: true + module Edtf module Humanize module Season + include Edtf::Humanize::Language - include Edtf::Humanize::Formats - def humanize - "#{apply_if_approximate(self)}"\ - "#{translate_season(self.season)} #{self.year}"\ - "#{apply_if_uncertain(self)}" + language_strategy::Season.humanizer(self) end - - private - - def translate_season(season) - begin - I18n.translate!("date.seasons.#{self.season}") - rescue I18n::MissingTranslationData - self.season - end - end - end end end