mirror of
https://github.com/django-q2/django-q2.git
synced 2026-10-05 03:18:12 +08:00
allow scheduler to schedule all pending tasks
This commit is contained in:
+2
-1
@@ -544,7 +544,8 @@ def scheduler(broker=None):
|
|||||||
# default behavior is to delete a ONCE schedule
|
# default behavior is to delete a ONCE schedule
|
||||||
if s.schedule_type == s.ONCE:
|
if s.schedule_type == s.ONCE:
|
||||||
if s.repeats < 0:
|
if s.repeats < 0:
|
||||||
return s.delete()
|
s.delete()
|
||||||
|
continue
|
||||||
# but not if it has a positive repeats
|
# but not if it has a positive repeats
|
||||||
s.repeats = 0
|
s.repeats = 0
|
||||||
# save the schedule
|
# save the schedule
|
||||||
|
|||||||
Reference in New Issue
Block a user