diff --git a/src/Core/Services/Implementations/UserService.cs b/src/Core/Services/Implementations/UserService.cs index eefadac2a..23ae1b362 100644 --- a/src/Core/Services/Implementations/UserService.cs +++ b/src/Core/Services/Implementations/UserService.cs @@ -213,7 +213,7 @@ namespace Bit.Core.Services string token, Guid? orgUserId) { var tokenValid = false; - if(!string.IsNullOrWhiteSpace(token) && orgUserId.HasValue) + if(_globalSettings.DisableUserRegistration && !string.IsNullOrWhiteSpace(token) && orgUserId.HasValue) { tokenValid = CoreHelpers.UserInviteTokenIsValid(_organizationServiceDataProtector, token, user.Email, orgUserId.Value);