[commands] Clean docstrings in Command.parents and Command.root_parent
This commit is contained in:
parent
6620fcc038
commit
c6410ea9ab
@ -507,14 +507,11 @@ class Command(_BaseCommand):
|
|||||||
def parents(self):
|
def parents(self):
|
||||||
"""Retrieves the parents of this command.
|
"""Retrieves the parents of this command.
|
||||||
|
|
||||||
.. versionadded:: 1.1.0
|
|
||||||
|
|
||||||
If the command has no parents then it returns an empty :class:`list`.
|
If the command has no parents then it returns an empty :class:`list`.
|
||||||
|
|
||||||
For example in commands ``?a b c test``,
|
For example in commands ``?a b c test``, the parents are ``[c, b, a]``.
|
||||||
the parents are ``[c, b, a]``.
|
|
||||||
|
|
||||||
|
|
||||||
|
.. versionadded:: 1.1.0
|
||||||
"""
|
"""
|
||||||
entries = []
|
entries = []
|
||||||
command = self
|
command = self
|
||||||
@ -530,8 +527,7 @@ class Command(_BaseCommand):
|
|||||||
|
|
||||||
If the command has no parents then it returns ``None``.
|
If the command has no parents then it returns ``None``.
|
||||||
|
|
||||||
For example in commands ``?a b c test``, the root parent is
|
For example in commands ``?a b c test``, the root parent is ``a``.
|
||||||
``a``.
|
|
||||||
"""
|
"""
|
||||||
if not self.parent:
|
if not self.parent:
|
||||||
return None
|
return None
|
||||||
|
Loading…
x
Reference in New Issue
Block a user