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 e12301c commit e13fb01Copy full SHA for e13fb01
src/Microsoft.OpenApi/Extensions/OpenApiTypeMapper.cs
@@ -3,6 +3,7 @@
3
4
using System;
5
using System.Collections.Generic;
6
+using Microsoft.OpenApi.Exceptions;
7
using Microsoft.OpenApi.Models;
8
9
namespace Microsoft.OpenApi.Extensions
@@ -49,7 +50,7 @@ public static JsonSchemaType IdentifierToEnumType(string identifier)
49
50
"array" => JsonSchemaType.Array,
51
"object" => JsonSchemaType.Object,
52
"file" => JsonSchemaType.String, // File is treated as string
- _ => throw new ArgumentException("Invalid schema type identifier", nameof(identifier))
53
+ _ => throw new OpenApiException(string.Format("Invalid schema type identifier", identifier))
54
};
55
}
56
0 commit comments