Yuki Takei 8 лет назад
Родитель
Сommit
e86f4d3201
1 измененных файлов с 3 добавлено и 1 удалено
  1. 3 1
      lib/routes/login-passport.js

+ 3 - 1
lib/routes/login-passport.js

@@ -105,11 +105,13 @@ module.exports = function(crowi, app) {
           });
           });
         })
         })
         .catch((err) => {
         .catch((err) => {
-          debug('findOrRegister error: ', err);
           if (err.name != null && err.name === 'DuplicatedUsernameException') {
           if (err.name != null && err.name === 'DuplicatedUsernameException') {
             req.flash('isDuplicatedUsernameExceptionOccured', true);
             req.flash('isDuplicatedUsernameExceptionOccured', true);
             return next();
             return next();
           }
           }
+          else {
+            return next(err);
+          }
         });
         });
 
 
     })(req, res, next);
     })(req, res, next);