From f23448be3340c56f6fae85b19a52aecf55e4753b Mon Sep 17 00:00:00 2001 From: guillaume Date: Thu, 22 Nov 2018 18:00:21 +0100 Subject: revert changes for patch authentication --- models/users.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'models/users.js') diff --git a/models/users.js b/models/users.js index 630f4703..2e879d94 100644 --- a/models/users.js +++ b/models/users.js @@ -520,10 +520,10 @@ if (Meteor.isServer) { } const disableRegistration = Settings.findOne().disableRegistration; - // If ldap, bypass the inviation code if the self registration isn't allowed. - // TODO : pay attention if ldap field in the user model change to another content ex : ldap field to connection_type - if (options.ldap || !disableRegistration) { - user.authenticationMethod = 'ldap'; + if (!disableRegistration) { + if (options.ldap) { + user.authenticationMethod = 'ldap'; + } return user; } -- cgit v1.2.3-1-g7c22