diff --git a/index.js b/index.js index 7dbae24..f4f3d34 100644 --- a/index.js +++ b/index.js @@ -1336,9 +1336,13 @@ dcClient.on('interactionCreate', async interaction => { result.unshift(fields); const csv = json2csv(result); const buffer = Buffer.from(csv, 'utf-8'); - const attachment = new MessageAttachment(buffer, 'cdr.csv'); interaction.editReply({ - files: [attachment], + files: [ + { + attachment: buffer, + name: "cdr.csv" + } + ], content: "Here are your CDR records" }); }