File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
api/src/discord/agile/commands Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change 44 Client ,
55 CommandInteraction ,
66 Guild ,
7+ ChatInputCommandInteraction ,
78} from "discord.js" ;
89import { Command } from "../../interfaces/command" ;
910import { getTaskFromId , setFlagForChallengeId } from "../../database/tasks" ;
@@ -43,7 +44,7 @@ export async function handleTaskSolved(
4344 message ?. react ( emojis [ Math . floor ( Math . random ( ) * emojis . length ) ] . toString ( ) ) ;
4445}
4546
46- async function solveTaskLogic ( client : Client , interaction : CommandInteraction ) {
47+ async function solveTaskLogic ( client : Client , interaction : ChatInputCommandInteraction ) {
4748 const r = await getCurrentTaskChannelFromDiscord ( interaction ) ;
4849 if ( r == null ) return accessDenied ( interaction ) ;
4950
@@ -93,7 +94,7 @@ export const SolveTask: Command = {
9394 } ,
9495 ] ,
9596 run : async ( client , interaction ) => {
96- return solveTaskLogic ( client , interaction ) . catch ( ( e ) => {
97+ return solveTaskLogic ( client , interaction as ChatInputCommandInteraction ) . catch ( ( e ) => {
9798 console . error ( "Error during solve task logic: " , e ) ;
9899 } ) ;
99100 } ,
You can’t perform that action at this time.
0 commit comments