Tweaks to mail generation.