Skip to content

Commit 57d3aa4

Browse files
Refactored waitGroup.Done() call.
1 parent f911876 commit 57d3aa4

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎src/chapter2/search/main.go‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,8 @@ func main() {
5757

5858
// Launch the goroutine to perform the search.
5959
go func() {
60-
defer waitGroup.Done()
6160
search.Search(matcher, searchTerm, results)
61+
waitGroup.Done()
6262
}()
6363
}
6464

0 commit comments

Comments
 (0)