Hy,
I'm on Symfony with MongoDb. I have a problem when I want update a document. This one has an embedded field. If I give it a not null value on POST, I can't update it to null when I patch.
When I POST :
"destination": {
"address1": "my address"
}
I have a good response :
"destination": {
"address1": "my address"
}
But when I want PATCH to null :
"destination": null
I always have :
"destination": {
"address1": "my address"
}
For PATCH I use Form Builder with my own FormType, I have this :
->add('destination', DestinationType::class, [
'required' => false,
])
And it's Ok for not embedded fields
Thank's