lib/rufus/scheduler.rb in rufus-scheduler-3.0.5 vs lib/rufus/scheduler.rb in rufus-scheduler-3.0.6

- old
+ new

@@ -36,11 +36,11 @@ require 'rufus/scheduler/util' require 'rufus/scheduler/jobs' require 'rufus/scheduler/cronline' require 'rufus/scheduler/job_array' - VERSION = '3.0.5' + VERSION = '3.0.6' # # A common error class for rufus-scheduler # class Error < StandardError; end @@ -122,10 +122,12 @@ def shutdown(opt=nil) @started_at = nil - jobs.each { |j| j.unschedule } + #jobs.each { |j| j.unschedule } + # provokes https://github.com/jmettraux/rufus-scheduler/issue/98 + @jobs.array.each { |j| j.unschedule } @work_queue.clear if opt == :wait join_all_work_threads