mirror of
https://github.com/django/django.git
synced 2025-10-23 21:59:11 +00:00
Fixed #23721 -- check_related_objects without calling __iter__
Refs #14334
This commit is contained in:
committed by
Anssi Kääriäinen
parent
00aa562884
commit
ae7cb992bc
@@ -408,6 +408,10 @@ class ObjectA(models.Model):
|
||||
def __str__(self):
|
||||
return self.name
|
||||
|
||||
def __iter__(self):
|
||||
# Ticket #23721
|
||||
assert False, 'type checking should happen without calling model __iter__'
|
||||
|
||||
|
||||
class ProxyObjectA(ObjectA):
|
||||
class Meta:
|
||||
|
||||
Reference in New Issue
Block a user