rufus-scheduler 1.0.8 → 1.0.9

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. data/CHANGELOG.txt +2 -1
  2. data/lib/rufus/scheduler.rb +13 -1
  3. metadata +1 -1
data/CHANGELOG.txt CHANGED
@@ -2,8 +2,9 @@
2
2
  = rufus-scheduler CHANGELOG.txt
3
3
 
4
4
 
5
- == rufus-scheduler - 1.0.8 released 2008/07/18
5
+ == rufus-scheduler - 1.0.9 released 2008/07/18
6
6
 
7
+ - bug #21262 : brought back (proxy) duration_to_f to Rufus::Scheduler
7
8
  - todo #21251 : added 'at', 'cron', 'in' and 'every' shortcut methods
8
9
  - todo #21203 : keeping track of At and EveryJob until last trigger is over
9
10
  - todo #20823 : now raising exception in case of bad 'at' parameter
@@ -452,6 +452,18 @@ module Rufus
452
452
  join
453
453
  end
454
454
 
455
+ #
456
+ # Ensures that a duration is a expressed as a Float instance.
457
+ #
458
+ # duration_to_f("10s")
459
+ #
460
+ # will yield 10.0
461
+ #
462
+ def duration_to_f (s)
463
+
464
+ Rufus.duration_to_f(s)
465
+ end
466
+
455
467
  #--
456
468
  #
457
469
  # The scheduling methods
@@ -501,7 +513,7 @@ module Rufus
501
513
  def schedule_in (duration, params={}, &block)
502
514
 
503
515
  do_schedule_at(
504
- Time.new.to_f + Rufus::duration_to_f(duration),
516
+ Time.new.to_f + Rufus.duration_to_f(duration),
505
517
  prepare_params(params),
506
518
  &block)
507
519
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rufus-scheduler
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.8
4
+ version: 1.0.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - John Mettraux