title: Why am I getting a null message?
body: <p>I keep getting a null after testing my register page. <a href="https://i.stack.imgur.com/dz9lU.png" rel="nofollow noreferrer">Null</a></p>
  <p>This is the code</p>
  <pre><code>app.post(&quot;/register&quot;, function (req, res) {
  const newUser = new User({
      email: req.body.email,
      password: req.body.password
  });
  
  newUser.save(function (err) {
      if (!err) {
          console.log(err);
      } else {
          res.render(&quot;secrets&quot;);
      }
  });
  </code></pre>
  <p>});</p>