diff options
| author | Stephan Groß | 2012-11-21 14:58:33 +0100 |
|---|---|---|
| committer | Stephan Groß | 2012-11-21 14:58:33 +0100 |
| commit | 774d687a311813a45ac9b2d3e1570c8bbca092fd (patch) | |
| tree | 4cc8c0169033b80b9a010f10f24bb8a722959f3a /rest_framework/serializers.py | |
| parent | 834f31ae4d77378f8a56b8647564b50c56bcabb8 (diff) | |
| download | django-rest-framework-774d687a311813a45ac9b2d3e1570c8bbca092fd.tar.bz2 | |
updated comparison due to pep8 programming recommendations
http://www.python.org/dev/peps/pep-0008/#programming-recommendations
Diffstat (limited to 'rest_framework/serializers.py')
| -rw-r--r-- | rest_framework/serializers.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/rest_framework/serializers.py b/rest_framework/serializers.py index f7918c4c..9f4964fa 100644 --- a/rest_framework/serializers.py +++ b/rest_framework/serializers.py @@ -460,7 +460,7 @@ class ModelSerializer(Serializer): """ self.m2m_data = {} - if instance: + if instance is not None: for key, val in attrs.items(): setattr(instance, key, val) return instance |
