fixed embeds in archive

This commit is contained in:
Isaac (eartharoid) 2020-08-25 22:44:40 +01:00
parent 8f5096ce5e
commit 8c4befad7b
2 changed files with 4 additions and 2 deletions

View File

@ -38,7 +38,8 @@ module.exports = {
let path = `user/transcripts/raw/${n.channel.id}.log`; let path = `user/transcripts/raw/${n.channel.id}.log`;
let embeds = []; let embeds = [];
for (let embed in n.embeds) for (let embed in n.embeds)
embeds.push(n.embeds[embed].toJSON()); // embeds.push(n.embeds[embed]); // n.embeds[embed].toJSON()
embeds[embed] = { ...n.embeds[embed] };
fs.appendFileSync(path, JSON.stringify({ fs.appendFileSync(path, JSON.stringify({
id: n.id, id: n.id,

View File

@ -34,7 +34,8 @@ module.exports.add = (message) => {
let embeds = []; let embeds = [];
for (let embed in message.embeds) for (let embed in message.embeds)
embeds.push(message.embeds[embed].toJSON()); // embeds.push(message.embeds[embed]); // .toJSON()
embeds[embed] = { ...message.embeds[embed] };
// message // message
fs.appendFileSync(raw, JSON.stringify({ fs.appendFileSync(raw, JSON.stringify({