Bare bones for JSON database

This commit is contained in:
privacy lulz committed 2021-09-01 20:17:52 +00:00
1 parent ee58f2d36c
commit 7ca4e650fb
4 files changed
+97 -3

No files matched your search

+2 -2
View File
@@ -208,7 +208,7 @@ class Cog(metaclass=CogMeta):
for command in self.__cog_commands__:
setattr(self, command.callback.__name__, command)
parent = command.parent
if parent is not None:
if parent:
# Get the latest parent reference
parent = lookup[parent.qualified_name] # type: ignore
@@ -230,7 +230,7 @@ class Cog(metaclass=CogMeta):
This does not include subcommands.
"""
return [c for c in self.__cog_commands__ if c.parent is None]
return [c for c in self.__cog_commands__ if not c.parent]
@property
def qualified_name(self) -> str: