diff --git a/django/contrib/admin/checks.py b/django/contrib/admin/checks.py
index f82c20c2f1..ba3270580a 100644
a
|
b
|
class ModelAdminChecks(BaseModelAdminChecks):
|
736 | 736 | ] |
737 | 737 | return [] |
738 | 738 | else: |
739 | | return [ |
740 | | checks.Error( |
741 | | "The value of '%s' refers to '%s', which is not a callable, " |
742 | | "an attribute of '%s', or an attribute or method on '%s.%s'." % ( |
743 | | label, item, obj.__class__.__name__, |
744 | | obj.model._meta.app_label, obj.model._meta.object_name, |
745 | | ), |
746 | | obj=obj.__class__, |
747 | | id='admin.E108', |
748 | | ) |
749 | | ] |
| 739 | try: |
| 740 | obj.model._meta.get_field(item) |
| 741 | except FieldDoesNotExist: |
| 742 | return [ |
| 743 | checks.Error( |
| 744 | "The value of '%s' refers to '%s', which is not a callable, " |
| 745 | "an attribute of '%s', or an attribute or method on '%s.%s'." % ( |
| 746 | label, item, obj.__class__.__name__, |
| 747 | obj.model._meta.app_label, obj.model._meta.object_name, |
| 748 | ), |
| 749 | obj=obj.__class__, |
| 750 | id='admin.E108', |
| 751 | ) |
| 752 | ] |
| 753 | return [] |
750 | 754 | |
751 | 755 | def _check_list_display_links(self, obj): |
752 | 756 | """ Check that list_display_links is a unique subset of list_display. |