lib/zhong/every.rb in zhong-0.2.2 vs lib/zhong/every.rb in zhong-0.2.3

- old
+ new

@@ -18,10 +18,10 @@ raise "`every` must be >= 1 second" unless valid? end def to_s EVERY_KEYWORDS.to_a.reverse.each do |friendly, period| - next unless @period % period == 0 + next unless @period.to_i % period.to_i == 0 rem = @period / period return "#{rem} #{friendly}" if rem == 1 return "#{rem} #{friendly}s"