MailToPdfFiles should close result channel and wait for the goroutines to finish