mirror of
https://github.com/bitwarden/server
synced 2025-12-22 03:03:33 +00:00
Revert filescoped (#2227)
* Revert "Add git blame entry (#2226)" This reverts commit239286737d. * Revert "Turn on file scoped namespaces (#2225)" This reverts commit34fb4cca2a.
This commit is contained in:
@@ -1,22 +1,23 @@
|
||||
using System.Text.Json;
|
||||
using Bit.Core.Entities;
|
||||
|
||||
namespace Bit.Api.Models.Public.Request;
|
||||
|
||||
public class PolicyUpdateRequestModel : PolicyBaseModel
|
||||
namespace Bit.Api.Models.Public.Request
|
||||
{
|
||||
public Policy ToPolicy(Guid orgId)
|
||||
public class PolicyUpdateRequestModel : PolicyBaseModel
|
||||
{
|
||||
return ToPolicy(new Policy
|
||||
public Policy ToPolicy(Guid orgId)
|
||||
{
|
||||
OrganizationId = orgId
|
||||
});
|
||||
}
|
||||
return ToPolicy(new Policy
|
||||
{
|
||||
OrganizationId = orgId
|
||||
});
|
||||
}
|
||||
|
||||
public virtual Policy ToPolicy(Policy existingPolicy)
|
||||
{
|
||||
existingPolicy.Enabled = Enabled.GetValueOrDefault();
|
||||
existingPolicy.Data = Data != null ? JsonSerializer.Serialize(Data) : null;
|
||||
return existingPolicy;
|
||||
public virtual Policy ToPolicy(Policy existingPolicy)
|
||||
{
|
||||
existingPolicy.Enabled = Enabled.GetValueOrDefault();
|
||||
existingPolicy.Data = Data != null ? JsonSerializer.Serialize(Data) : null;
|
||||
return existingPolicy;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user