made working version of mail server, two problems : code under run can be simplified (see notes) and body of email is only recording every other line ??