only log in to smtp server if username or password are set
Merge pull request #4 from gregbanks/allow-passwordless-smtp

only log in to smtp server if username or password is set