mirror of
https://github.com/edgebox-iot/edgeboxctl.git
synced 2026-09-25 14:20:56 +02:00
Fix wrong handling of task arguments in systemIterator
This commit is contained in:
@@ -115,7 +115,11 @@ func systemIterator(name *string, tick int) {
|
|||||||
tasks.ExecuteSchedules(tick)
|
tasks.ExecuteSchedules(tick)
|
||||||
nextTask := tasks.GetNextTask()
|
nextTask := tasks.GetNextTask()
|
||||||
if nextTask.Task != "" {
|
if nextTask.Task != "" {
|
||||||
log.Printf("Executing task %s / Args: %s", nextTask.Task, nextTask.Args)
|
taskArguments := "No arguments"
|
||||||
|
if nextTask.Args.Valid {
|
||||||
|
taskArguments = nextTask.Args.String
|
||||||
|
}
|
||||||
|
log.Printf("Executing task %s / Args: %s", nextTask.Task, taskArguments)
|
||||||
tasks.ExecuteTask(nextTask)
|
tasks.ExecuteTask(nextTask)
|
||||||
} else {
|
} else {
|
||||||
log.Printf("No tasks to execute.")
|
log.Printf("No tasks to execute.")
|
||||||
|
|||||||
Reference in New Issue
Block a user