fix sendemail issue