mirror of
https://github.com/Hessenuk/DiscordTickets.git
synced 2024-11-09 14:23:08 +02:00
fix edit topic log
This commit is contained in:
parent
3c8ba79b87
commit
3ee972c9ff
@ -29,6 +29,7 @@ module.exports = class TopicModal extends Modal {
|
|||||||
},
|
},
|
||||||
id: true,
|
id: true,
|
||||||
openingMessageId: true,
|
openingMessageId: true,
|
||||||
|
topic: true,
|
||||||
};
|
};
|
||||||
const original = await client.prisma.ticket.findUnique({
|
const original = await client.prisma.ticket.findUnique({
|
||||||
select,
|
select,
|
||||||
@ -41,7 +42,7 @@ module.exports = class TopicModal extends Modal {
|
|||||||
});
|
});
|
||||||
const getMessage = client.i18n.getLocale(ticket.guild.locale);
|
const getMessage = client.i18n.getLocale(ticket.guild.locale);
|
||||||
|
|
||||||
if (topic) await interaction.channel.setTopic(`<@${ticket.createdById}> | ${topic}`);
|
if (topic) interaction.channel.setTopic(`<@${ticket.createdById}> | ${topic}`);
|
||||||
|
|
||||||
const opening = await interaction.channel.messages.fetch(ticket.openingMessageId);
|
const opening = await interaction.channel.messages.fetch(ticket.openingMessageId);
|
||||||
if (opening && opening.embeds.length >= 2) {
|
if (opening && opening.embeds.length >= 2) {
|
||||||
|
Loading…
Reference in New Issue
Block a user