mirror of
https://github.com/bitwarden/server.git
synced 2024-11-29 13:25:17 +01:00
dotnet format
This commit is contained in:
parent
9a5f1e2598
commit
5bb005354b
@ -2,7 +2,6 @@
|
||||
|
||||
using Bit.Core.AdminConsole.Entities;
|
||||
using Bit.Core.AdminConsole.Enums;
|
||||
using Bit.Core.Entities;
|
||||
|
||||
namespace Bit.Core.AdminConsole.OrganizationFeatures.Policies;
|
||||
|
||||
|
@ -1,13 +1,10 @@
|
||||
#nullable enable
|
||||
|
||||
using System.ComponentModel;
|
||||
using Bit.Core.AdminConsole.Entities;
|
||||
using Bit.Core.AdminConsole.Enums;
|
||||
using Bit.Core.AdminConsole.Repositories;
|
||||
using Bit.Core.Auth.Enums;
|
||||
using Bit.Core.Auth.Repositories;
|
||||
using Bit.Core.Context;
|
||||
using Bit.Core.Entities;
|
||||
using Bit.Core.Enums;
|
||||
using Bit.Core.Exceptions;
|
||||
using Bit.Core.Repositories;
|
||||
|
@ -82,9 +82,9 @@ public class PolicyServicevNext : IPolicyServicevNext
|
||||
.Where(otherPolicy => otherPolicy is { Enabled: true })
|
||||
.ToList();
|
||||
|
||||
if (dependentPolicies is { Count: > 0})
|
||||
if (dependentPolicies is { Count: > 0 })
|
||||
{
|
||||
throw new BadRequestException("This policy is required by " + dependentPolicies.First()!.Type + " policy. Try disabling that policy first." );
|
||||
throw new BadRequestException("This policy is required by " + dependentPolicies.First()!.Type + " policy. Try disabling that policy first.");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1,11 +1,9 @@
|
||||
#nullable enable
|
||||
|
||||
using System.Reflection;
|
||||
using AutoFixture;
|
||||
using AutoFixture.Kernel;
|
||||
using Bit.Core.AdminConsole.OrganizationFeatures.Policies;
|
||||
using Bit.Core.AdminConsole.Services.Implementations;
|
||||
using Bit.Test.Common.AutoFixture.Attributes;
|
||||
|
||||
namespace Bit.Core.Test.AdminConsole.AutoFixture;
|
||||
|
||||
|
@ -13,7 +13,6 @@ using Bit.Core.Test.AdminConsole.AutoFixture;
|
||||
using Bit.Test.Common.AutoFixture;
|
||||
using Bit.Test.Common.AutoFixture.Attributes;
|
||||
using NSubstitute;
|
||||
using NSubstitute.ReceivedExtensions;
|
||||
using Xunit;
|
||||
using EventType = Bit.Core.Enums.EventType;
|
||||
|
||||
@ -99,7 +98,7 @@ public class PolicyServicevNextTests
|
||||
}
|
||||
|
||||
[Theory, BitAutoData]
|
||||
public async Task SaveAsync_PolicyDefinitionNotFound_Throws([Policy(PolicyType.SingleOrg)]Policy policy)
|
||||
public async Task SaveAsync_PolicyDefinitionNotFound_Throws([Policy(PolicyType.SingleOrg)] Policy policy)
|
||||
{
|
||||
var sutProvider = SutProviderFactory();
|
||||
ArrangeOrganization(sutProvider, policy);
|
||||
|
Loading…
Reference in New Issue
Block a user