Only send welcome mails for non admins
This can only ever be an admin here if it is the very first one.
This commit is contained in:
+2
-1
@@ -127,7 +127,8 @@ function createUser(username, password, email, admin, callback) {
|
||||
|
||||
callback(null, user);
|
||||
|
||||
mailer.userAdded(user, password);
|
||||
// only send welcome mail if user is not an admin. This i only the case for the first user!
|
||||
if (!user.admin) mailer.userAdded(user, password);
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user