Fixed: bug in email sending procedure.