aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Common/Json/Converters/JsonNullableStructConverterFactory.cs
diff options
context:
space:
mode:
authorBond_009 <bond.009@outlook.com>2021-05-05 12:57:01 +0200
committerBond_009 <bond.009@outlook.com>2021-05-05 12:57:01 +0200
commit91c2a57b284011a21c926e9238dbc7edb5eaab13 (patch)
tree6aa65ceabd25e4ea4ad87fffe0e0596450c50cae /MediaBrowser.Common/Json/Converters/JsonNullableStructConverterFactory.cs
parent48e81e65e8948fa61980744932eb4103a28ed876 (diff)
Enable nullable reference types for MediaBrowser.Common
Diffstat (limited to 'MediaBrowser.Common/Json/Converters/JsonNullableStructConverterFactory.cs')
-rw-r--r--MediaBrowser.Common/Json/Converters/JsonNullableStructConverterFactory.cs6
1 files changed, 3 insertions, 3 deletions
diff --git a/MediaBrowser.Common/Json/Converters/JsonNullableStructConverterFactory.cs b/MediaBrowser.Common/Json/Converters/JsonNullableStructConverterFactory.cs
index d5b54e3ca..e2a3d798a 100644
--- a/MediaBrowser.Common/Json/Converters/JsonNullableStructConverterFactory.cs
+++ b/MediaBrowser.Common/Json/Converters/JsonNullableStructConverterFactory.cs
@@ -18,10 +18,10 @@ namespace MediaBrowser.Common.Json.Converters
}
/// <inheritdoc />
- public override JsonConverter CreateConverter(Type typeToConvert, JsonSerializerOptions options)
+ public override JsonConverter? CreateConverter(Type typeToConvert, JsonSerializerOptions options)
{
var structType = typeToConvert.GenericTypeArguments[0];
- return (JsonConverter)Activator.CreateInstance(typeof(JsonNullableStructConverter<>).MakeGenericType(structType));
+ return (JsonConverter?)Activator.CreateInstance(typeof(JsonNullableStructConverter<>).MakeGenericType(structType));
}
}
-} \ No newline at end of file
+}