Skip to content

Commit

Permalink
Ignore errors from CustomRegex so the channel doesn't leak (trufflese…
Browse files Browse the repository at this point in the history
  • Loading branch information
mcastorina authored Mar 15, 2023
1 parent f0b6b5d commit 0fe9bf0
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions pkg/custom_detectors/custom_detectors.go
Original file line number Diff line number Diff line change
Expand Up @@ -94,9 +94,8 @@ func (c *customRegexWebhook) FromData(ctx context.Context, verify bool, data []b
})
}

if err := g.Wait(); err != nil {
return nil, err
}
// Ignore any errors and collect as many of the results as we can.
_ = g.Wait()
close(resultsCh)

for result := range resultsCh {
Expand Down

0 comments on commit 0fe9bf0

Please sign in to comment.