mirror of
https://github.com/bitwarden/server.git
synced 2024-11-22 12:15:36 +01:00
only check token valid if registration is disabled
This commit is contained in:
parent
938b7f1230
commit
49947e382d
@ -213,7 +213,7 @@ namespace Bit.Core.Services
|
|||||||
string token, Guid? orgUserId)
|
string token, Guid? orgUserId)
|
||||||
{
|
{
|
||||||
var tokenValid = false;
|
var tokenValid = false;
|
||||||
if(!string.IsNullOrWhiteSpace(token) && orgUserId.HasValue)
|
if(_globalSettings.DisableUserRegistration && !string.IsNullOrWhiteSpace(token) && orgUserId.HasValue)
|
||||||
{
|
{
|
||||||
tokenValid = CoreHelpers.UserInviteTokenIsValid(_organizationServiceDataProtector, token,
|
tokenValid = CoreHelpers.UserInviteTokenIsValid(_organizationServiceDataProtector, token,
|
||||||
user.Email, orgUserId.Value);
|
user.Email, orgUserId.Value);
|
||||||
|
Loading…
Reference in New Issue
Block a user