mirror of
https://github.com/Hessenuk/DiscordTickets.git
synced 2024-11-17 09:23:07 +02:00
fix: don't throw errors on every message if a guild isn't configured
This commit is contained in:
parent
df725185eb
commit
62ab9eb6c7
@ -181,6 +181,7 @@ module.exports = class extends Listener {
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
const settings = await client.prisma.guild.findUnique({ where: { id: message.guild.id } });
|
const settings = await client.prisma.guild.findUnique({ where: { id: message.guild.id } });
|
||||||
|
if (!settings) return;
|
||||||
let ticket = await client.prisma.ticket.findUnique({ where: { id: message.channel.id } });
|
let ticket = await client.prisma.ticket.findUnique({ where: { id: message.channel.id } });
|
||||||
|
|
||||||
if (ticket) {
|
if (ticket) {
|
||||||
|
Loading…
Reference in New Issue
Block a user