mirror of
https://github.com/Hessenuk/DiscordTickets.git
synced 2024-12-23 00:03:09 +02:00
fixed new.js
This commit is contained in:
parent
d4522cd729
commit
60044a1e70
@ -38,7 +38,9 @@ module.exports = {
|
||||
|
||||
};
|
||||
|
||||
message.guild.createChannel(`ticket-${id}`).then(async c => {
|
||||
message.guild.createChannel(`ticket-${id}`, {
|
||||
type: 'text'
|
||||
}).then(async c => {
|
||||
c.setParent(config.ticketsCat);
|
||||
// let supportRole = message.guild.roles.find(`id`, config.supportRole)
|
||||
let supportRole = message.guild.roles.get(config.supportRole)
|
||||
@ -65,7 +67,9 @@ module.exports = {
|
||||
};
|
||||
|
||||
if (config.ticketImage) {
|
||||
await c.send(`__**Here's your ticket channel, ${message.author}**__`,{files: [`./image.png`]})
|
||||
await c.send(`__**Here's your ticket channel, ${message.author}**__`, {
|
||||
files: [`./image.png`]
|
||||
})
|
||||
} else {
|
||||
await c.send(`__**Here's your ticket channel, ${message.author}**__`)
|
||||
}
|
||||
@ -102,7 +106,9 @@ module.exports = {
|
||||
.addField("Channel", c, true)
|
||||
.setFooter(`DiscordTickets`)
|
||||
.setTimestamp();
|
||||
client.channels.get(config.logChannel).send({embed})
|
||||
client.channels.get(config.logChannel).send({
|
||||
embed
|
||||
})
|
||||
} else {
|
||||
client.channels.get(config.logChannel).send(`New ticket created by **${message.author.tag} (${message.author.id})**`);
|
||||
}
|
||||
|
@ -4,8 +4,8 @@
|
||||
"description": "A Discord ticket/support - an open-source & self-hosted bot",
|
||||
"main": "index.js",
|
||||
"dependencies": {
|
||||
"discord.js": "^11.4.2",
|
||||
"leekslazylogger": "^1.1.3"
|
||||
"discord.js": "^11.5.1",
|
||||
"leekslazylogger": "^1.1.7"
|
||||
},
|
||||
"devDependencies": {},
|
||||
"scripts": {
|
||||
|
Loading…
Reference in New Issue
Block a user