Optimize sending mails.