BUGFIX: correct return values and clean up code

The return values were missing, indicating whether the email could be sent. Along with that I have just cleaned up some indents.