Skip to content

Commit c03f5e5

Browse files
Merge branch 'master' into bootstrap-dist.js
2 parents 459d3ca + a9b7d1f commit c03f5e5

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

rest_framework_docs/api_docs.py

+1-3
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,7 @@ def get_all_view_names(self, urlpatterns, parent_pattern=None):
2424

2525
def _is_drf_view(self, pattern):
2626
# Should check whether a pattern inherits from DRF's APIView
27-
if (hasattr(pattern.callback, 'cls') and issubclass(pattern.callback.cls, APIView)):
28-
return True
29-
return False
27+
return hasattr(pattern.callback, 'cls') and issubclass(pattern.callback.cls, APIView)
3028

3129
def get_endpoints(self):
3230
return self.endpoints

0 commit comments

Comments
 (0)