Skip to content

Commit

Permalink
Merge pull request #45 from rick2047/fix_repeated_scheduler
Browse files Browse the repository at this point in the history
fix schedule_interval, typo in constructor call
  • Loading branch information
aviks authored Jul 24, 2021
2 parents 160eaf5 + 004b358 commit db2da3d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/timer.jl
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ function schedule_unique(f::Function, interval)
end

function schedule_interval(f::Function, interval, first_interval=interval)
push!(scheduler[], RepeatScheduled(WeakRef(f), elapsed(scheduler[])+first_interval*1e9), interval*1e9 )
push!(scheduler[], RepeatScheduled(WeakRef(f), elapsed(scheduler[])+first_interval*1e9, interval*1e9 ))
@debug "Added Repeated Schedule" f
end
unschedule(f::Function) = filter!(WeakRef(f), scheduler[])

0 comments on commit db2da3d

Please sign in to comment.