1313from pydis_core .utils .scheduling import Scheduler
1414
1515from bot .bot import Bot
16- from bot .constants import MODERATION_ROLES , RedirectOutput
16+ from bot .constants import MODERATION_ROLES , RedirectOutput , Roles
1717from bot .converters import Inventory , PackageName , ValidURL
1818from bot .log import get_logger
1919from bot .pagination import LinePaginator
@@ -349,7 +349,7 @@ def base_url_from_inventory_url(inventory_url: str) -> str:
349349 return inventory_url .removesuffix ("/" ).rsplit ("/" , maxsplit = 1 )[0 ] + "/"
350350
351351 @docs_group .command (name = "setdoc" , aliases = ("s" ,))
352- @commands .has_any_role (* MODERATION_ROLES )
352+ @commands .has_any_role (* MODERATION_ROLES , Roles . core_developers )
353353 @lock (NAMESPACE , COMMAND_LOCK_SINGLETON , raise_error = True )
354354 async def set_command (
355355 self ,
@@ -397,7 +397,7 @@ async def set_command(
397397 await ctx .send (f"Added the package `{ package_name } ` to the database and updated the inventories." )
398398
399399 @docs_group .command (name = "deletedoc" , aliases = ("removedoc" , "rm" , "d" ))
400- @commands .has_any_role (* MODERATION_ROLES )
400+ @commands .has_any_role (* MODERATION_ROLES , Roles . core_developers )
401401 @lock (NAMESPACE , COMMAND_LOCK_SINGLETON , raise_error = True )
402402 async def delete_command (self , ctx : commands .Context , package_name : PackageName ) -> None :
403403 """
@@ -414,7 +414,7 @@ async def delete_command(self, ctx: commands.Context, package_name: PackageName)
414414 await ctx .send (f"Successfully deleted `{ package_name } ` and refreshed the inventories." )
415415
416416 @docs_group .command (name = "refreshdoc" , aliases = ("rfsh" , "r" ))
417- @commands .has_any_role (* MODERATION_ROLES )
417+ @commands .has_any_role (* MODERATION_ROLES , Roles . core_developers )
418418 @lock (NAMESPACE , COMMAND_LOCK_SINGLETON , raise_error = True )
419419 async def refresh_command (self , ctx : commands .Context ) -> None :
420420 """Refresh inventories and show the difference."""
@@ -436,7 +436,7 @@ async def refresh_command(self, ctx: commands.Context) -> None:
436436 await ctx .send (embed = embed )
437437
438438 @docs_group .command (name = "cleardoccache" , aliases = ("deletedoccache" ,))
439- @commands .has_any_role (* MODERATION_ROLES )
439+ @commands .has_any_role (* MODERATION_ROLES , Roles . core_developers )
440440 async def clear_cache_command (
441441 self ,
442442 ctx : commands .Context ,
0 commit comments