mirror of
https://github.com/Hessenuk/DiscordTickets.git
synced 2025-02-23 10:51:22 +02:00
fix: only send transcript button if archiving is enabled
This commit is contained in:
parent
13f3427ba7
commit
618f35f247
@ -631,20 +631,22 @@ module.exports = class TicketManager {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
await channel.send({
|
await channel.send({
|
||||||
components: [
|
components: category.guild.archive
|
||||||
new ActionRowBuilder()
|
? [
|
||||||
.addComponents(
|
new ActionRowBuilder()
|
||||||
new ButtonBuilder()
|
.addComponents(
|
||||||
.setCustomId(JSON.stringify({
|
new ButtonBuilder()
|
||||||
action: 'transcript',
|
.setCustomId(JSON.stringify({
|
||||||
ticket: referencesTicketId,
|
action: 'transcript',
|
||||||
}))
|
ticket: referencesTicketId,
|
||||||
.setStyle(ButtonStyle.Primary)
|
}))
|
||||||
.setEmoji(getMessage('buttons.transcript.emoji'))
|
.setStyle(ButtonStyle.Primary)
|
||||||
.setLabel(getMessage('buttons.transcript.text')),
|
.setEmoji(getMessage('buttons.transcript.emoji'))
|
||||||
|
.setLabel(getMessage('buttons.transcript.text')),
|
||||||
|
|
||||||
),
|
),
|
||||||
],
|
]
|
||||||
|
: [],
|
||||||
embeds: [embed],
|
embeds: [embed],
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user