Przeglądaj źródła

Modified null check

Norio Suzuki 8 lat temu
rodzic
commit
0ad3673069
1 zmienionych plików z 1 dodań i 1 usunięć
  1. 1 1
      lib/routes/me.js

+ 1 - 1
lib/routes/me.js

@@ -90,7 +90,7 @@ module.exports = function(crowi, app) {
       }
 
       User.findOne({email: email}, (err, existingUserData) => {
-        if (existingUserData !== null) {
+        if (existingUserData) {
           debug('Email address was duplicated');
           req.form.errors.push('It can not be changed to that mail address');
           return res.render('me/index', {});