def to_seconds(base = nil)
      valid_base?(base)
      return factor(base) * atom if base.nil?
      target = ::Time.new(base.year + atom.to_i, base.month, base.day, base.hour, base.minute, base.second, base.zone)

      target - base.to_time
    end
def to_seconds(base = nil)
      valid_base?(base)
      return factor(base) * atom if base.nil?
      target = ::Time.new(base.year + atom.to_i, base.month, base.day, base.hour, base.minute, base.second, base.zone)

      target - base.to_time
    end
The amount of seconds

 TODO: Fractions of year will fail

 @param [ISO8601::DateTime, nil] base (nil) The base datetime to compute
   the year length.

 @return [Numeric]
 rubocop:disable Metrics/AbcSize