Add message and ticket referencing, fixes

This commit is contained in:
Isaac
2022-08-13 23:01:44 +01:00
parent f6666b103e
commit c64b18a397
10 changed files with 262 additions and 38 deletions

View File

@@ -1,4 +1,5 @@
const { MessageCommand } = require('@eartharoid/dbf');
const { useGuild } = require('../../lib/tickets/utils');
module.exports = class CreateMessageCommand extends MessageCommand {
constructor(client, options) {
@@ -13,7 +14,11 @@ module.exports = class CreateMessageCommand extends MessageCommand {
});
}
/**
* @param {import("discord.js").MessageContextMenuCommandInteraction} interaction
*/
async run(interaction) {
// TODO: archive message
await useGuild(this.client, interaction, { referencesMessage: interaction.targetMessage.channelId + '/' + interaction.targetId });
}
};