Skip to content

Commit 6a0ccc5

Browse files
committed
test
1 parent b841318 commit 6a0ccc5

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

internal/service/segment_service.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -519,7 +519,8 @@ func calculateNext5AMInTimezone(tz string) (time.Time, error) {
519519

520520
// If we've already passed 5 AM today, move to tomorrow
521521
if now.After(next5AM) || now.Equal(next5AM) {
522-
next5AM = next5AM.Add(24 * time.Hour)
522+
tomorrow := now.AddDate(0, 0, 1)
523+
next5AM = time.Date(tomorrow.Year(), tomorrow.Month(), tomorrow.Day(), 5, 0, 0, 0, loc)
523524
}
524525

525526
// Convert to UTC for storage

0 commit comments

Comments
 (0)