Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions public/language/sc/error.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"invalid-path": "Invalid path",
"folder-exists": "Folder exists",
"invalid-pagination-value": "Invalid pagination value, must be at least %1 and at most %2",
"username-taken": "Username taken",
"username-taken": "Username taken, try: %1",
"email-taken": "Email taken",
"email-nochange": "The email entered is the same as the email already on file.",
"email-invited": "Email was already invited",
Expand Down Expand Up @@ -221,4 +221,4 @@
"api.500": "An unexpected error was encountered while attempting to service your request.",
"api.501": "The route you are trying to call is not implemented yet, please try again tomorrow",
"api.503": "The route you are trying to call is not currently available due to a server configuration"
}
}
2 changes: 1 addition & 1 deletion src/user/approval.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ module.exports = function (User) {
await User.isDataValid(userData);
const usernames = await db.getSortedSetRange('registration:queue', 0, -1);
if (usernames.includes(userData.username)) {
throw new Error('[[error:username-taken]]');
throw new Error('[[error:username-taken, ${userData.username + "1"}]]');
}
const keys = usernames.filter(Boolean).map(username => `registration:queue:name:${username}`);
const data = await db.getObjectsFields(keys, ['email']);
Expand Down