mirror of
https://github.com/django/django.git
synced 2024-12-22 17:16:24 +00:00
parent
4492be348a
commit
8a2ec55b18
@ -27,7 +27,7 @@ class OptionsBaseTests(SimpleTestCase):
|
||||
return None if model == current_model else model
|
||||
|
||||
def _details(self, current_model, relation):
|
||||
direct = isinstance(relation, Field) or isinstance(relation, GenericForeignKey)
|
||||
direct = isinstance(relation, (Field, GenericForeignKey))
|
||||
model = relation.model._meta.concrete_model
|
||||
if model == current_model:
|
||||
model = None
|
||||
|
Loading…
Reference in New Issue
Block a user