lib/fugit/nat.rb in fugit-1.5.3 vs lib/fugit/nat.rb in fugit-1.6.0
- old
+ new
@@ -13,9 +13,11 @@
return s if s.is_a?(Fugit::Cron) || s.is_a?(Fugit::Duration)
return nil unless s.is_a?(String)
+ s = s.strip
+
#p s; Raabro.pp(Parser.parse(s, debug: 3), colours: true)
#(p s; Raabro.pp(Parser.parse(s, debug: 1), colours: true)) rescue nil
if slots = Parser.parse(s)
slots.to_crons(opts.merge(_s: s))