From b15a6ccef2e13ab3310dbe856a945bba56e21c63 Mon Sep 17 00:00:00 2001 From: Tom Christie Date: Sun, 2 Jun 2013 20:12:49 +0100 Subject: Serializer field 'default' argument may be a callable --- docs/api-guide/fields.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'docs/api-guide') diff --git a/docs/api-guide/fields.md b/docs/api-guide/fields.md index 9820cb40..c7db32ed 100644 --- a/docs/api-guide/fields.md +++ b/docs/api-guide/fields.md @@ -41,7 +41,9 @@ Defaults to `True`. ### `default` -If set, this gives the default value that will be used for the field if none is supplied. If not set the default behavior is to not populate the attribute at all. +If set, this gives the default value that will be used for the field if none is supplied. If not set the default behavior is to not populate the attribute at all. + +May be set to a function or other callable, in which case the value will be evaluated each time it is used. ### `validators` -- cgit v1.2.3