File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -70,7 +70,7 @@ class MyViewSet(viewsets.ModelViewSet):
7070 return qs
7171
7272
73- class SelectAndPrefetchForIncludesMixin (object ):
73+ class PreloadIncludesMixin (object ):
7474 """
7575 This mixin provides a helper attributes to select or prefetch related models
7676 based on the include specified in the URL.
@@ -92,7 +92,7 @@ class MyViewSet(viewsets.ModelViewSet):
9292 }
9393 """
9494 def get_queryset (self ):
95- qs = super (SelectAndPrefetchForIncludesMixin , self ).get_queryset ()
95+ qs = super (PreloadIncludesMixin , self ).get_queryset ()
9696
9797 includes = self .request .GET .get ('include' , '' ).split (',' ) + ['__all__' ]
9898
@@ -237,14 +237,14 @@ def get_related_instance(self):
237237
238238
239239class ModelViewSet (AutoPrefetchMixin ,
240- SelectAndPrefetchForIncludesMixin ,
240+ PreloadIncludesMixin ,
241241 RelatedMixin ,
242242 viewsets .ModelViewSet ):
243243 pass
244244
245245
246246class ReadOnlyModelViewSet (AutoPrefetchMixin ,
247- SelectAndPrefetchForIncludesMixin ,
247+ PreloadIncludesMixin ,
248248 RelatedMixin ,
249249 viewsets .ReadOnlyModelViewSet ):
250250 pass
You can’t perform that action at this time.
0 commit comments