Add logging to emailed messages for debugging later