250763 (1) [Avatar] Offline
#1
POST /edit handler doesn't appear to be working and just hangs as currently implemented (unless i'm missing something). Worked around it quickly:

router.post("/edit", ensureAuthenticated, function(req, res, next) {


  User.update({_id: req.user._id}, {
    displayName: req.body.displayname,
    bio: req.body.bio
  }, function(err) {

    if (err) {
      next(err);
      return;
    }
    
    req.flash("info", "Profile updated!");
    res.redirect("/edit");
  });
  
});
Evan Hahn (70) [Avatar] Offline
#2
Thanks! I'll fix this.