Skip to content

Commit 31812bd

Browse files
committed
Refactor primary_key_field_name
1 parent 5c8109d commit 31812bd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

django_elasticsearch_dsl/documents.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ def get_queryset(self):
6969
"""
7070
Return the queryset that should be indexed by this doc type.
7171
"""
72-
primary_key_field_name = self.django.model_meta.pk.name
72+
primary_key_field_name = self.django.model._meta.pk.name
7373
return self.django.model._default_manager.all().order_by(primary_key_field_name)
7474

7575
def prepare(self, instance):

0 commit comments

Comments
 (0)