mirror of
https://github.com/bitwarden/server.git
synced 2025-06-30 15:42:48 -05:00
Permissions bugs (#1083)
* Null checked org invite collections * Null checked permissions on org invite * Gave a static seat count to org invite fixture * Null checked the right way
This commit is contained in:
@ -1022,11 +1022,15 @@ namespace Bit.Core.Services
|
||||
ExternalId = externalId,
|
||||
CreationDate = DateTime.UtcNow,
|
||||
RevisionDate = DateTime.UtcNow,
|
||||
Permissions = System.Text.Json.JsonSerializer.Serialize(invite.Permissions, new JsonSerializerOptions
|
||||
};
|
||||
|
||||
if (invite.Permissions != null)
|
||||
{
|
||||
orgUser.Permissions = System.Text.Json.JsonSerializer.Serialize(invite.Permissions, new JsonSerializerOptions
|
||||
{
|
||||
PropertyNamingPolicy = JsonNamingPolicy.CamelCase,
|
||||
}),
|
||||
};
|
||||
});
|
||||
}
|
||||
|
||||
if (!orgUser.AccessAll && invite.Collections.Any())
|
||||
{
|
||||
|
Reference in New Issue
Block a user