mirror of
https://github.com/bitwarden/server
synced 2026-01-04 09:33:40 +00:00
Turn on file scoped namespaces (#2225)
This commit is contained in:
@@ -1,18 +1,17 @@
|
||||
using System.Text.Json;
|
||||
using System.Text.Json.Serialization;
|
||||
|
||||
namespace Bit.Core.Utilities
|
||||
namespace Bit.Core.Utilities;
|
||||
|
||||
public class HandlebarsObjectJsonConverter : JsonConverter<object>
|
||||
{
|
||||
public class HandlebarsObjectJsonConverter : JsonConverter<object>
|
||||
public override bool CanConvert(Type typeToConvert) => true;
|
||||
public override object Read(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options)
|
||||
{
|
||||
public override bool CanConvert(Type typeToConvert) => true;
|
||||
public override object Read(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options)
|
||||
{
|
||||
return JsonSerializer.Deserialize<Dictionary<string, object>>(ref reader, options);
|
||||
}
|
||||
public override void Write(Utf8JsonWriter writer, object value, JsonSerializerOptions options)
|
||||
{
|
||||
JsonSerializer.Serialize(writer, value, options);
|
||||
}
|
||||
return JsonSerializer.Deserialize<Dictionary<string, object>>(ref reader, options);
|
||||
}
|
||||
public override void Write(Utf8JsonWriter writer, object value, JsonSerializerOptions options)
|
||||
{
|
||||
JsonSerializer.Serialize(writer, value, options);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user