Fixed SMTP Bugs

Problems were being raised with the smtp connections. Fixed.
Fixed Login Crash Due to Timeout

Login keys were expiring when trying to send notification of new post.
Fixed by logging back into the server if there is a new post. Prevents
key timeouts.