Przeglądaj źródła

Bug fix: verifying email gave an error message to the user.
Verifying email now gives success message and redirects to login.

Lee Morgan 5 lat temu
rodzic
commit
5b43a17b01
1 zmienionych plików z 2 dodań i 2 usunięć
  1. 2 2
      controllers/emailVerification.js

+ 2 - 2
controllers/emailVerification.js

@@ -78,9 +78,9 @@ module.exports = {
                 return merchant.save();
             })
             .then((merchant)=>{
-                req.session.user = merchant._id;
+                req.session.success = "EMAIL VERIFIED.  PLEASE LOG IN";
 
-                return res.redirect("/dashboard");
+                return res.redirect("/login");
             })
             .catch((err)=>{
                 if(typeof(err) === "string"){