@@ -646,6 +646,7 @@ async def set_presence(
646646 @tasks .loop (minutes = 45 )
647647 async def loop_presence (self ):
648648 """Set presence to the configured value every 45 minutes."""
649+ # TODO: Does this even work?
649650 presence = await self .set_presence ()
650651 logger .debug (f'{ presence ["activity" ][1 ]} { presence ["status" ][1 ]} ' )
651652
@@ -1295,10 +1296,6 @@ async def permissions_override(
12951296 command .qualified_name
12961297 ] = level .name
12971298
1298- if not any (check for check in command .checks if hasattr (check , "permission_level" )):
1299- logger .debug ('Command %s has no permissions check, adding invalid.' , command .qualified_name )
1300- checks .has_permissions (PermissionLevel .INVALID )(command )
1301-
13021299 await self .bot .config .update ()
13031300 embed = Embed (
13041301 title = "Success" ,
@@ -1618,25 +1615,37 @@ async def permissions_get(
16181615 for command in self .bot .walk_commands ():
16191616 if command not in done :
16201617 done .add (command )
1621- level = self .bot .config ["override_command_level" ].get (command .qualified_name )
1618+ level = self .bot .config ["override_command_level" ].get (
1619+ command .qualified_name
1620+ )
16221621 if level is not None :
16231622 overrides [command .qualified_name ] = level
16241623
16251624 embeds = []
16261625 if not overrides :
1627- embeds .append (Embed (
1628- title = "Permission Overrides" ,
1629- description = "You don't have any command level overrides at the moment." ,
1630- color = Color .red ()
1631- ))
1626+ embeds .append (
1627+ Embed (
1628+ title = "Permission Overrides" ,
1629+ description = "You don't have any command level overrides at the moment." ,
1630+ color = Color .red (),
1631+ )
1632+ )
16321633 else :
1633- for items in zip_longest (* (iter (sorted (overrides .items ())),) * 15 ):
1634+ for items in zip_longest (
1635+ * (iter (sorted (overrides .items ())),) * 15
1636+ ):
16341637 description = "\n " .join (
16351638 ": " .join ((f"`{ name } `" , level ))
1636- for name , level in takewhile (lambda x : x is not None , items )
1639+ for name , level in takewhile (
1640+ lambda x : x is not None , items
1641+ )
1642+ )
1643+ embed = Embed (
1644+ color = self .bot .main_color , description = description
1645+ )
1646+ embed .set_author (
1647+ name = "Permission Overrides" , icon_url = ctx .guild .icon_url
16371648 )
1638- embed = Embed (color = self .bot .main_color , description = description )
1639- embed .set_author (name = "Permission Overrides" , icon_url = ctx .guild .icon_url )
16401649 embeds .append (embed )
16411650
16421651 session = EmbedPaginatorSession (ctx , * embeds )
0 commit comments