Add lookup as well

This commit is contained in:
Christopher Cookman 2025-10-02 02:27:39 -06:00
parent 00fe44c380
commit 99d996818b

View file

@ -12,7 +12,7 @@ const execute = async (interaction, db, client) => {
fields: [
{ name: "Reported By", value: `<@${row.reportedBy}>`, inline: true },
{ name: "Comment", value: row.comment || "No comment provided", inline: false },
{ name: "Timestamp", value: `<t:${Math.floor(new Date(row.timestamp)/1000)}>`, inline: true }
{ name: "Timestamp", value: `<t:${Math.floor(new Date(row.timestamp) / 1000)}>`, inline: true }
],
color: 0x00ff00
};
@ -21,7 +21,10 @@ const execute = async (interaction, db, client) => {
if (row.attachments) {
try {
const attachments = JSON.parse(row.attachments);
files = attachments.map(file => path.join(__dirname, '../../storage', file));
files = attachments.map(file => ({
attachment: path.join(__dirname, '../../storage', file),
name: `SPOILER_${file}`
}))
} catch (e) {
files = [];
}