Skip to content

Commit

Permalink
lintfix
Browse files Browse the repository at this point in the history
  • Loading branch information
lingrino committed Oct 14, 2020
1 parent 2651f9d commit 52c2c95
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions vaku/helpers.go
Expand Up @@ -68,17 +68,6 @@ func InsertIntoPath(path, after, insert string) string {
return PathJoin(after, insert, strings.TrimPrefix(path, after))
}

// waitFuncOnChan takes a function like waitgroup.Wait() and provides a channel that will be closed
// when the provided function returns. Makes it easy to wait inside of a select statement.
func waitFuncOnChan(waitFunc func()) <-chan struct{} {
done := make(chan struct{})
go func() {
waitFunc()
close(done)
}()
return done
}

// errFuncOnChan takes a function like errgroup.Wait() and provides a channel that can be read for
// the err value that the function returns. Makes it easy to wait inside of a select statement.
func errFuncOnChan(errFunc func() error) <-chan error {
Expand Down

0 comments on commit 52c2c95

Please sign in to comment.