defect fixes for email in production