We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fcbabd4 commit 538013dCopy full SHA for 538013d
src/Microsoft.OpenApi/Validations/Rules/RuleHelpers.cs
@@ -1,4 +1,4 @@
1
-// Copyright (c) Microsoft Corporation. All rights reserved.
+// Copyright (c) Microsoft Corporation. All rights reserved.
2
// Licensed under the MIT license.
3
4
using System;
@@ -52,7 +52,7 @@ public static void ValidateDataTypeMismatch(
52
return;
53
}
54
55
- var type = schema.GetJsonType().Value.GetDisplayName();
+ var type = schema.GetJsonType()?.GetDisplayName();
56
var format = schema.GetFormat()?.Key;
57
var jsonElement = JsonSerializer.Deserialize<JsonElement>(value);
58
0 commit comments