This repository was archived by the owner on Feb 13, 2022. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change 77
88from bot import constants , logger
99from bot .bot import ThreadBot
10+ from bot .exts import ban_appeals
1011from bot .exts .ban_appeals import BASE_RESPONSE , _api_handlers , _models
1112
1213
@@ -73,6 +74,16 @@ async def embed_test(self, ctx: commands.Context) -> None:
7374 await self .appeal_channel .send ("New ban appeal!" , embed = embed )
7475 await ctx .message .add_reaction ("✅" )
7576
77+ @commands .has_any_role (* constants .MODERATION_ROLES )
78+ @ban_appeal .command (name = "responses" , aliases = ("get" , "list" ))
79+ async def list_responses (self , ctx : commands .Context , response : t .Optional [_models .AppealResponse ]) -> None :
80+ """List all available canned responses. If a response name is given, output the contents of that response."""
81+ if response :
82+ await ctx .send (response )
83+ return
84+ response_keys = [f"`{ key } `" for key in ban_appeals .APPEAL_RESPONSES ]
85+ await ctx .send (f"Response options are: { ', ' .join (response_keys )} " )
86+
7687 @commands .has_any_role (constants .Roles .admins )
7788 @ban_appeal .command (name = "respond" , aliases = ("response" ,))
7889 async def appeal_respond (
You can’t perform that action at this time.
0 commit comments