Skip to content

Commit 11b930b

Browse files
committed
fixed nullable multipart file not registering proper schema
1 parent 41d5f80 commit 11b930b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/kotlin/com/papsign/ktor/openapigen/content/type/multipart/MultipartFormDataContentProvider.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ object MultipartFormDataContentProvider : BodyParser {
4040
private class Registrar(val previous: SchemaRegistrar) : SchemaRegistrar {
4141

4242
override fun get(type: KType, master: SchemaRegistrar): NamedSchema {
43-
return if (streamTypes.contains(type)) {
43+
return if (streamTypes.contains(type.withNullability(false))) {
4444
NamedSchema(
4545
"InputStream", Schema.SchemaLitteral(
4646
DataType.string,

0 commit comments

Comments
 (0)