fix email in use meshctrl reply #6036
Signed-off-by: si458 <simonsmith5521@gmail.com>
This commit is contained in:
parent
f39b6f8859
commit
1747ff7550
12
meshuser.js
12
meshuser.js
|
@ -5792,10 +5792,14 @@ module.exports.CreateMeshUser = function (parent, db, ws, req, args, domain, use
|
|||
}
|
||||
return;
|
||||
}
|
||||
|
||||
for(var x in parent.users) {
|
||||
if(parent.users[x].email==command.email){
|
||||
displayNotificationMessage("Email address already in use", "New Account", "ServerNotify");
|
||||
for (var x in parent.users) {
|
||||
if (parent.users[x].email == command.email){
|
||||
if (command.responseid != null) {
|
||||
obj.send({ action: 'adduser', responseid: command.responseid, result: "Email address already in use", msgid: errid });
|
||||
} else {
|
||||
// Send error back, user not found.
|
||||
displayNotificationMessage("Email address already in use", "New Account", 'ServerNotify', 1, errid, args);
|
||||
}
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue