diff --git a/openapi3/reflect.go b/openapi3/reflect.go index 4f7bca4..a340648 100644 --- a/openapi3/reflect.go +++ b/openapi3/reflect.go @@ -250,7 +250,7 @@ func (r *Reflector) parseParametersIn( s := SchemaOrRef{} s.FromJSONSchema(propertySchema.ToSchemaOrBool()) - if s.Schema != nil && s.Schema.Nullable != nil { + if s.Schema != nil && s.Schema.Nullable != nil && field.Type.Kind() != reflect.Ptr { s.Schema.Nullable = nil }