function handler(req, res) {
  console.log(
    `Failed login attempt for: ${(req.body || {}).email} from ${
      req.ip
    } UA ${req.get("User-Agent")}`
  );
  req.flash(
    "error",
    "You've made too many failed attempts in a short period of time, please try again " +
      moment(req.rateLimit.resetTime).fromNow()
  );
  res.redirect("/auth/login"); // brute force protection triggered, send them back to the login page
}
@param {object} req
@param {object} res
@returns {void}