We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 550ed3a commit b17548bCopy full SHA for b17548b
1 file changed
Command/ListCronTasksCommand.php
@@ -28,7 +28,7 @@ protected function execute(InputInterface $input, OutputInterface $output)
28
];
29
30
foreach ($this->getContainer()->get('axiolab.crontask.manager')->findAll() as $task) {
31
- $nextExecutionDT = $task->getLastRun()->add(new \DateInterval($task->getExecutionInterval()));
+ $nextExecutionDT = $task->getLastRun() ? $task->getLastRun()->add(new \DateInterval($task->getExecutionInterval())) : $task->getFirstRun();
32
$rows[] = [
33
$task->getAlias(),
34
$this->trans('axiolab.crontask.status.'.$task->getCronStatus()),
0 commit comments