Skip to content

Commit

Permalink
Add a docstring to LenChecker.base_classes_of_node
Browse files Browse the repository at this point in the history
  • Loading branch information
Pierre-Sassoulas committed Sep 7, 2020
1 parent d0bbc81 commit e18f51c
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions pylint/checkers/refactoring/len_checker.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,7 @@ def visit_unaryop(self, node):

@staticmethod
def base_classes_of_node(instance: astroid.nodes.ClassDef) -> List[astroid.Name]:
"""Return all the classes names that a ClassDef inherit from including 'object'."""
mother_classes = [instance.name]
base_classes = instance.bases
while base_classes and "object" not in mother_classes:
Expand Down

0 comments on commit e18f51c

Please sign in to comment.