wait group wrapper