ESLint - Fix mixed conditionals

This commit is contained in:
André Zanghelini
2017-06-08 15:37:37 -03:00
parent 2aca811256
commit 391aa6e67e

View File

@@ -44,7 +44,7 @@ authenticationController.register = function (req, res) {
err = '[[error:invalid-email]]';
}
if (!err && !userData.username || userData.username.length < meta.config.minimumUsernameLength) {
if (!err && (!userData.username || userData.username.length < meta.config.minimumUsernameLength)) {
err = '[[error:username-too-short]]';
}