support cron schedule range values

This commit is contained in:
jesopo 2019-12-12 12:06:02 +00:00
parent 48bab203bf
commit 2084285480

View file

@ -40,6 +40,10 @@ class Module(ModuleManager.BaseModule):
if (timestamp_part%schedule_step) == 0:
return True
elif "-" in schedule_part:
left, right = schedule_part.split("-", 1)
return int(left) <= timestamp_part <= int(right)
elif schedule_part == "*":
return True