File tree Expand file tree Collapse file tree 1 file changed +1
-10
lines changed
src/StrawberryShake/Client/src/Core/Serialization Expand file tree Collapse file tree 1 file changed +1
-10
lines changed Original file line number Diff line number Diff line change @@ -15,16 +15,7 @@ public JsonSerializer(string typeName = BuiltInScalarNames.Any)
15
15
16
16
public override JsonElement Parse ( JsonElement serializedValue )
17
17
{
18
- using var writer = new ArrayWriter ( ) ;
19
-
20
- // write json value to buffer.
21
- using var jsonWriter = new Utf8JsonWriter ( writer ) ;
22
- serializedValue . WriteTo ( jsonWriter ) ;
23
- jsonWriter . Flush ( ) ;
24
-
25
- // now we read the buffer and create an element that does not need to be disposed.
26
- var reader = new Utf8JsonReader ( writer . GetWrittenSpan ( ) , true , default ) ;
27
- return JsonElement . ParseValue ( ref reader ) ;
18
+ return serializedValue . Clone ( ) ;
28
19
}
29
20
30
21
protected override JsonElement Format ( JsonElement runtimeValue )
You can’t perform that action at this time.
0 commit comments