Clarify some users.length
that were forgotten in a previous PR
This commit is contained in:
parent
252dca3d3f
commit
234fd31411
@ -41,7 +41,7 @@ ClientManager.prototype.autoloadUsers = function() {
|
||||
process.exit(1);
|
||||
}
|
||||
|
||||
if (!users.length) {
|
||||
if (users.length === 0) {
|
||||
log.info(noUsersWarning);
|
||||
}
|
||||
|
||||
@ -51,7 +51,7 @@ ClientManager.prototype.autoloadUsers = function() {
|
||||
const loaded = this.clients.map((c) => c.name);
|
||||
const updatedUsers = this.getUsers();
|
||||
|
||||
if (!updatedUsers.length) {
|
||||
if (updatedUsers.length === 0) {
|
||||
log.info(noUsersWarning);
|
||||
}
|
||||
|
||||
|
@ -28,12 +28,12 @@ program
|
||||
return;
|
||||
}
|
||||
|
||||
if (!users.length) {
|
||||
log.info(`There are currently no users. Create one with ${colors.bold("lounge add <name>")}.`);
|
||||
} else {
|
||||
if (users.length > 0) {
|
||||
log.info("Users:");
|
||||
for (var i = 0; i < users.length; i++) {
|
||||
log.info(`${i + 1}. ${colors.bold(users[i])}`);
|
||||
}
|
||||
users.forEach((user, i) => {
|
||||
log.info(`${i + 1}. ${colors.bold(user)}`);
|
||||
});
|
||||
} else {
|
||||
log.info(`There are currently no users. Create one with ${colors.bold("lounge add <name>")}.`);
|
||||
}
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user