aboutsummaryrefslogtreecommitdiffstats
path: root/docs/topics/3.0-announcement.md
diff options
context:
space:
mode:
Diffstat (limited to 'docs/topics/3.0-announcement.md')
-rw-r--r--docs/topics/3.0-announcement.md6
1 files changed, 1 insertions, 5 deletions
diff --git a/docs/topics/3.0-announcement.md b/docs/topics/3.0-announcement.md
index bffc608a..b28670cf 100644
--- a/docs/topics/3.0-announcement.md
+++ b/docs/topics/3.0-announcement.md
@@ -191,7 +191,7 @@ Using the `depth` option on `ModelSerializer` will now create **read-only nested
def create(self, validated_data):
profile_data = validated_data.pop['profile']
user = User.objects.create(**validated_data)
- profile = Profile.objects.create(user=user, **profile_data)
+ Profile.objects.create(user=user, **profile_data)
return user
The single-step object creation makes this far simpler and more obvious than the previous `.restore_object()` behavior.
@@ -223,10 +223,6 @@ We can now inspect the serializer representation in the Django shell, using `pyt
rating = IntegerField()
created_by = PrimaryKeyRelatedField(queryset=User.objects.all())
-#### Always use `fields`, not `exclude`.
-
-The `exclude` option on `ModelSerializer` is no longer available. You should use the more explicit `fields` option instead.
-
#### The `extra_kwargs` option.
The `write_only_fields` option on `ModelSerializer` has been moved to `PendingDeprecation` and replaced with a more generic `extra_kwargs`.