|
|
|
@ -268,7 +268,6 @@ function createAdmin(callback) {
|
|
|
|
|
var User = require('./user');
|
|
|
|
|
var Groups = require('./groups');
|
|
|
|
|
var password;
|
|
|
|
|
var meta = require('./meta');
|
|
|
|
|
|
|
|
|
|
winston.warn('No administrators have been detected, running initial user setup\n');
|
|
|
|
|
|
|
|
|
@ -309,8 +308,10 @@ function createAdmin(callback) {
|
|
|
|
|
return retryPassword(results);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (results.password.length < meta.config.minimumPasswordLength) {
|
|
|
|
|
winston.warn('Password too short, please try again');
|
|
|
|
|
try {
|
|
|
|
|
User.isPasswordValid(results.password);
|
|
|
|
|
} catch (err) {
|
|
|
|
|
winston.warn('Password error, please try again. ' + err.message);
|
|
|
|
|
return retryPassword(results);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|