title: SMTP nodemailer, works in localhost not in production
body: <p>I deployed an application to the free tier of Heroku, using nodemailer i setup an option in the app for me to receive some <code>JSON</code> from a form, and use that information to email myself, in localhost, this works fine, ive tested it extensively to be sure that it would work, but when i went to test this in production i found that it is only returning a 400 bad request, this is the status code, i return on something going wrong in the server logic.</p>
  <pre><code>/*
    @Desc:   Allows a user to send a support email
    @Route:  POST /api/support
    @access: Public
  */
  export const sendSupportMail = asyncHandler(async (req, res) =&gt; {
    const message =
      `Name: ${req.body.name} \n` +
      `Email: ${req.body.email} \n` +
      `Phone: ${req.body.phone} \n` +
      `Message: ${req.body.message} \n`;
    try {
      await sendEmail({
        email: process.env.SUPPORT_EMAIL,
        subject: `Support Email`,
        message: message,
      });
      res.status(200).json({ success: true });
    } catch (error) {
      res.status(400).json({ success: false, error });
    }
  });
  
  </code></pre>
  <p>This all worked in localhost, I've been looking around on the net, and im pretty sure this is an issue because of the free-tier hosting of heroku, however before i commit myself to upgrading the tier, id like to try to fix it before hand or atleast get a good explanation of why this isnt working.</p>