some changes in sending mail