Use timedelta to avoid ValueError

This commit is contained in:
tcely authored and GitHub committed 2025-06-07 19:28:18 -04:00
1 parent 4dc7243972
commit af4f242b05
1 file changed
+1 -1
+1 -1
View File
@@ -404,7 +404,7 @@ class Source(db.models.Model):
)
elif Val(IndexSchedule.EVERY_7_DAYS) > self.index_schedule:
self.target_schedule = advance_hour(
when.replace(hour=1+when.hour),
when + timezone.timedelta(hours=1),
self.target_schedule.hour,
)