Remove ruledropper (#4449)

This commit is contained in:
Stonedestroyer 2020-10-14 22:34:45 +02:00 committed by GitHub
parent c441857a4c
commit e1c745fe3c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1148,7 +1148,7 @@ class RedBase(
def remove_cog(self, cogname: str): def remove_cog(self, cogname: str):
cog = self.get_cog(cogname) cog = self.get_cog(cogname)
if cog is None or isinstance(cog, commands.commands._RuleDropper): if cog is None:
return return
for cls in inspect.getmro(cog.__class__): for cls in inspect.getmro(cog.__class__):
@ -1305,9 +1305,6 @@ class RedBase(
subcommand.requires.ready_event.set() subcommand.requires.ready_event.set()
def remove_command(self, name: str) -> None: def remove_command(self, name: str) -> None:
command = self.get_command(name)
if isinstance(command, commands.commands._RuleDropper):
return
command = super().remove_command(name) command = super().remove_command(name)
if not command: if not command:
return return