Skip to content

Commit

Permalink
too many functions. whoops
Browse files Browse the repository at this point in the history
  • Loading branch information
djeebus committed Dec 8, 2023
1 parent 2c4593e commit 67ef961
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions pkg/events/check.go
Original file line number Diff line number Diff line change
Expand Up @@ -362,11 +362,11 @@ Check kubechecks application logs for more information.
`
)

func (ce *CheckEvent) createRunner(span trace.Span, grpCtx context.Context, app string, wg *sync.WaitGroup) func(string, checkFunction) func() {
wg.Add(1)
func (ce *CheckEvent) createRunner(span trace.Span, grpCtx context.Context, app string, wg *sync.WaitGroup) func(string, checkFunction) {
return func(desc string, fn checkFunction) {
wg.Add(1)

return func(desc string, fn checkFunction) func() {
return func() {
go func() {
defer func() {
wg.Done()

Expand All @@ -392,7 +392,7 @@ func (ce *CheckEvent) createRunner(span trace.Span, grpCtx context.Context, app
ce.vcsNote.AddToAppMessage(grpCtx, app, cr)

ce.logger.Info().Str("app", app).Str("check", desc).Str("result", cr.State.String()).Msgf("check done")
}
}()
}
}

Expand Down

0 comments on commit 67ef961

Please sign in to comment.