1
0
mirror of https://github.com/bitwarden/server.git synced 2025-07-04 09:32:48 -05:00

[AC-2426] Allow editing of client organization name (#4072)

* Allow editing of client organization name

* Removing unnecessary using for linter
This commit is contained in:
Alex Morask
2024-05-14 11:26:08 -04:00
committed by GitHub
parent e93894a6fd
commit fd173e81b6
3 changed files with 59 additions and 5 deletions

View File

@ -133,10 +133,17 @@ public class ProviderClientsController(
return TypedResults.Problem();
}
await assignSeatsToClientOrganizationCommand.AssignSeatsToClientOrganization(
provider,
clientOrganization,
requestBody.AssignedSeats);
if (clientOrganization.Seats != requestBody.AssignedSeats)
{
await assignSeatsToClientOrganizationCommand.AssignSeatsToClientOrganization(
provider,
clientOrganization,
requestBody.AssignedSeats);
}
clientOrganization.Name = requestBody.Name;
await organizationRepository.ReplaceAsync(clientOrganization);
return TypedResults.Ok();
}