mirror of
https://github.com/encode/django-rest-framework.git
synced 2024-11-11 04:07:39 +03:00
Merge branch 'master' of https://github.com/woakas/django-rest-framework
This commit is contained in:
commit
01e80ff9f7
|
@ -250,6 +250,9 @@ class WritableField(Field):
|
|||
self.validators = self.default_validators + validators
|
||||
self.default = default if default is not None else self.default
|
||||
|
||||
if is_simple_callable(self.default):
|
||||
self.default = self.default()
|
||||
|
||||
# Widgets are ony used for HTML forms.
|
||||
widget = widget or self.widget
|
||||
if isinstance(widget, type):
|
||||
|
|
Loading…
Reference in New Issue
Block a user