Tweak comment.

This commit is contained in:
Tom Christie 2013-01-03 22:06:55 +00:00
parent 6da21fa796
commit 7ed81c3c66

View File

@ -187,9 +187,8 @@ class WritableField(Field):
native = data[field_name]
except KeyError:
if self.default is not None and not self.root.partial:
# Note: partial updates shouldn't set defaults
native = self.default
# partial serializers shouldn't set the default field to avoid
# overriding the previously set value
else:
if self.required:
raise ValidationError(self.error_messages['required'])