Express inside next () returns an undefined status?

  node.js, question

In doing login registration module.

In the registration function inside, if no user name is entered, an error prompt will be sent through the next middleware. No error will be thrown here, so the http status should be 200, but it is undefined.

Ask for guidance.

clipboard.png

app.js

clipboard.png

Error prompt

clipboard.png

This is an error in the send method. send only accepts one parameter.