Getiing error during email send process
MailSystemInterface::mail has a particular return value:


  TRUE if the mail was successfully accepted for delivery, otherwise FALSE.


The caller uses that to determine whether or not the mail was sent successfully, so just return TRUE when the mail succeeds and the error will stop.