Add the ability to send email notifications when a task fails.