Skip to content
This repository has been archived by the owner on Aug 31, 2022. It is now read-only.

Commit

Permalink
Merge pull request #1 from kontur-click/instance-check
Browse files Browse the repository at this point in the history
fixed child instance miki725#68
  • Loading branch information
Dexes authored Jul 9, 2019
2 parents e502e74 + 4c454e4 commit 539ce2c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion rest_framework_bulk/drf3/serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ def to_internal_value(self, data):

for item in data:
try:
self.child.instance = self.instance.get(id=item['id'])
self.child.instance = self.instance.get(id=item['id']) if self.instance else None
self.child.initial_data = item
validated = self.child.run_validation(item)
except ValidationError as exc:
Expand Down

0 comments on commit 539ce2c

Please sign in to comment.