diff --git a/internal/deprecated/workflow/job.go b/internal/deprecated/workflow/job.go index a1c9485d9..181f85121 100644 --- a/internal/deprecated/workflow/job.go +++ b/internal/deprecated/workflow/job.go @@ -137,7 +137,7 @@ func (s *state) createJob(ctx context.Context, actions []rufio.Action, name jobN } // create a new job - hw , err := hardwareFrom(ctx, s.client, s.workflow) + hw, err := hardwareFrom(ctx, s.client, s.workflow) if err != nil { return reconcile.Result{}, fmt.Errorf("error getting hardware: %w", err) } diff --git a/internal/deprecated/workflow/journal/journal.go b/internal/deprecated/workflow/journal/journal.go index bc32a6aa2..5dabcf8be 100644 --- a/internal/deprecated/workflow/journal/journal.go +++ b/internal/deprecated/workflow/journal/journal.go @@ -32,11 +32,14 @@ func Log(ctx context.Context, msg string, args ...any) { t := time.Now().UTC().Format(time.RFC3339Nano) m := make(map[string]any) for i := 0; i < len(args); i += 2 { - m[args[i].(string)] = args[i+1] + k, ok := args[i].(string) + if !ok { + k = "invalid key" + } + m[k] = args[i+1] } e, ok := ctx.Value(Name).(*[]Entry) if !ok { - e = &[]Entry{{Msg: msg, Args: m, Source: fileAndLine(), Time: t}} return } *e = append(*e, Entry{Msg: msg, Args: m, Source: fileAndLine(), Time: t})