Replaced quit channel with a WaitGroup. This better matches what is happening.