insert child

This commit is contained in:
Willem Van Onsem 2024-01-29 12:57:12 +01:00
parent 094521c8d8
commit bcbd26d32e

View File

@ -152,9 +152,7 @@ class BaseSerializer(Field):
if value is not None:
list_kwargs[key] = value
child_serializer = cls(*args, **kwargs)
list_kwargs = {
'child': child_serializer,
}
list_kwargs['child'] = child_serializer
list_kwargs.update({
key: value for key, value in kwargs.items()
if key in LIST_SERIALIZER_KWARGS