Fixed #124 : DMs are now sent to ticket creator

This commit is contained in:
DJj123dj
2025-01-25 11:18:10 +01:00
parent d35eb8f8bf
commit 057a5fc6ae
11 changed files with 22 additions and 11 deletions
+2 -1
View File
@@ -59,7 +59,8 @@ export const registerActions = async () => {
}
//to dm
if (generalConfig.data.system.messages.removing.dm) await openticket.client.sendUserDm(user,await openticket.builders.messages.getSafe("openticket:ticket-action-dm").build(source,{guild,channel,user,ticket,mode:"remove",reason,additionalData:data}))
const creator = await openticket.tickets.getTicketUser(ticket,"creator")
if (creator && generalConfig.data.system.messages.removing.dm) await openticket.client.sendUserDm(creator,await openticket.builders.messages.getSafe("openticket:ticket-action-dm").build(source,{guild,channel,user,ticket,mode:"remove",reason,additionalData:data}))
}),
new api.ODWorker("openticket:logs",0,(instance,params,source,cancel) => {
const {guild,channel,user,ticket,data} = params