@@ -818,15 +818,15 @@ func (d dailyJob) next(lastRun time.Time) time.Time {
818
818
}
819
819
firstPass = false
820
820
821
- startNextDay := time .Date (lastRun .Year (), lastRun .Month (), lastRun .Day ()+ int (d .interval ), 0 , 0 , 0 , lastRun . Nanosecond () , lastRun .Location ())
821
+ startNextDay := time .Date (lastRun .Year (), lastRun .Month (), lastRun .Day ()+ int (d .interval ), 0 , 0 , 0 , 0 , lastRun .Location ())
822
822
return d .nextDay (startNextDay , firstPass )
823
823
}
824
824
825
825
func (d dailyJob ) nextDay (lastRun time.Time , firstPass bool ) time.Time {
826
826
for _ , at := range d .atTimes {
827
827
// sub the at time hour/min/sec onto the lastScheduledRun's values
828
828
// to use in checks to see if we've got our next run time
829
- atDate := time .Date (lastRun .Year (), lastRun .Month (), lastRun .Day (), at .Hour (), at .Minute (), at .Second (), lastRun . Nanosecond () , lastRun .Location ())
829
+ atDate := time .Date (lastRun .Year (), lastRun .Month (), lastRun .Day (), at .Hour (), at .Minute (), at .Second (), 0 , lastRun .Location ())
830
830
831
831
if firstPass && atDate .After (lastRun ) {
832
832
// checking to see if it is after i.e. greater than,
@@ -872,7 +872,7 @@ func (w weeklyJob) nextWeekDayAtTime(lastRun time.Time, firstPass bool) time.Tim
872
872
for _ , at := range w .atTimes {
873
873
// sub the at time hour/min/sec onto the lastScheduledRun's values
874
874
// to use in checks to see if we've got our next run time
875
- atDate := time .Date (lastRun .Year (), lastRun .Month (), lastRun .Day ()+ int (weekDayDiff ), at .Hour (), at .Minute (), at .Second (), lastRun . Nanosecond () , lastRun .Location ())
875
+ atDate := time .Date (lastRun .Year (), lastRun .Month (), lastRun .Day ()+ int (weekDayDiff ), at .Hour (), at .Minute (), at .Second (), 0 , lastRun .Location ())
876
876
877
877
if firstPass && atDate .After (lastRun ) {
878
878
// checking to see if it is after i.e. greater than,
@@ -940,7 +940,7 @@ func (m monthlyJob) nextMonthDayAtTime(lastRun time.Time, days []int, firstPass
940
940
for _ , at := range m .atTimes {
941
941
// sub the day, and the at time hour/min/sec onto the lastScheduledRun's values
942
942
// to use in checks to see if we've got our next run time
943
- atDate := time .Date (lastRun .Year (), lastRun .Month (), day , at .Hour (), at .Minute (), at .Second (), lastRun . Nanosecond () , lastRun .Location ())
943
+ atDate := time .Date (lastRun .Year (), lastRun .Month (), day , at .Hour (), at .Minute (), at .Second (), 0 , lastRun .Location ())
944
944
945
945
if atDate .Month () != lastRun .Month () {
946
946
// this check handles if we're setting a day not in the current month
0 commit comments