mirror of
https://github.com/encode/django-rest-framework.git
synced 2025-08-05 13:00:12 +03:00
Remove unreachable code
This commit is contained in:
parent
06a5bcc88e
commit
d18b1f351c
|
@ -132,13 +132,6 @@ class UniqueTogetherValidator(object):
|
||||||
"""
|
"""
|
||||||
Filter the queryset to all instances matching the given attributes.
|
Filter the queryset to all instances matching the given attributes.
|
||||||
"""
|
"""
|
||||||
# If this is an update, then any unprovided field should
|
|
||||||
# have it's value set based on the existing instance attribute.
|
|
||||||
if self.instance is not None:
|
|
||||||
for field_name in self.fields:
|
|
||||||
if field_name not in attrs:
|
|
||||||
attrs[field_name] = getattr(self.instance, field_name)
|
|
||||||
|
|
||||||
# Determine the filter keyword arguments and filter the queryset.
|
# Determine the filter keyword arguments and filter the queryset.
|
||||||
filter_kwargs = {
|
filter_kwargs = {
|
||||||
field_name: attrs[field_name]
|
field_name: attrs[field_name]
|
||||||
|
|
Loading…
Reference in New Issue
Block a user