More precise assertion error for bulk update

This commit is contained in:
Tom Christie 2014-11-06 11:10:36 +00:00
parent ed541864e6
commit 4482be46ae

View File

@ -525,11 +525,11 @@ class ListSerializer(BaseSerializer):
def save(self, **kwargs): def save(self, **kwargs):
assert self.instance is None, ( assert self.instance is None, (
"Serializers do not support multiple update by default, because " "Serializers do not support multiple update by default, only "
"it would be unclear how to deal with insertions, updates and " "multiple create. For updates it is unclear how to deal with "
"deletions. If you need to support multiple update, use a " "insertions and deletions. If you need to support multiple update, "
"`ListSerializer` class and override `.save()` so you can specify " "use a `ListSerializer` class and override `.save()` so you can "
"the behavior exactly." "specify the behavior exactly."
) )
validated_data = [ validated_data = [