fixed some issues with localhost and from in mailer