From 35092c1d7bfe6021405b87b55fe798b9ce29c7dc Mon Sep 17 00:00:00 2001 From: desjoerd Date: Tue, 7 Jan 2025 22:02:56 +0100 Subject: [PATCH] =?UTF-8?q?=F0=9F=A9=B9=20Remove=20not=20needed=20reflecti?= =?UTF-8?q?on=20in=20OptionalValueJsonConverterAttribute?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/OptionalValues/OptionalValueJsonConverterAttribute.cs | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/OptionalValues/OptionalValueJsonConverterAttribute.cs b/src/OptionalValues/OptionalValueJsonConverterAttribute.cs index 0cfbd9c..0091b53 100644 --- a/src/OptionalValues/OptionalValueJsonConverterAttribute.cs +++ b/src/OptionalValues/OptionalValueJsonConverterAttribute.cs @@ -40,13 +40,7 @@ protected OptionalValueJsonConverterAttribute() { JsonConverter innerConverter = CreateInnerConverter(); - return (JsonConverter?)Activator.CreateInstance( - type: typeof(OptionalValueJsonConverterFactory), - bindingAttr: BindingFlags.NonPublic | BindingFlags.Instance, - args: [innerConverter], - binder: null, - culture: null - ); + return new OptionalValueJsonConverterFactory(innerConverter); } ///