Unfortunately
a75e8c9 did not fix the problem as intended, values below 60 do not modify the date of next execution. This is caused by the way CronjobUtil disregards any timeframe below 1 minute (seconds aren't allowed for value anyway). To avoid this issue I've picked 120 seconds which is more than 1 minute (preventing nasty rounding errors) and far less to have any impact on the system.
$nextExec = $cronjob->getNextExec();
$cronjob->update(array(
'nextExec' => $nextExec,
- 'afterNextExec' => $cronjob->getNextExec(($nextExec + 1))
+ 'afterNextExec' => $cronjob->getNextExec(($nextExec + 120))
));
// build the return value
// get time of next execution
$nextExec = $cronjobEditor->getNextExec();
- $afterNextExec = $cronjobEditor->getNextExec(($nextExec + 1));
+ $afterNextExec = $cronjobEditor->getNextExec(($nextExec + 120));
// mark cronjob as done
$cronjobEditor->update(array(