change createMessage to send (eris to d.js)

This commit is contained in:
Emily 2021-07-15 12:39:19 +10:00
parent abc21ac158
commit 9d0fd0ee01
23 changed files with 71 additions and 71 deletions

View file

@ -23,17 +23,17 @@ module.exports = class {
const clean = await client.functions.clean(evaled);
const MAX_CHARS = 3 + 2 + clean.length + 3;
if (MAX_CHARS > 2000) {
return message.channel.createMessage(undefined, { file: Buffer.from(clean), name: 'EVAL_SUCCESS.js' });
return message.channel.send(undefined, { file: Buffer.from(clean), name: 'EVAL_SUCCESS.js' });
}
message.channel.createMessage(`\`\`\`js\n${clean}\n\`\`\``);
message.channel.send(`\`\`\`js\n${clean}\n\`\`\``);
} catch (err) {
const e = await client.functions.clean(err);
const MAX_CHARS = 3 + 2 + e.length + 3;
if (MAX_CHARS > 2000) {
return message.channel.createMessage(undefined, { file: Buffer.from(e), name: 'EVAL_ERROR.txt' });
return message.channel.send(undefined, { file: Buffer.from(e), name: 'EVAL_ERROR.txt' });
}
message.channel.createMessage(`\`\`\`xl\n${e}\n\`\`\``);
message.channel.send(`\`\`\`xl\n${e}\n\`\`\``);
}
}
};

View file

@ -19,6 +19,6 @@ module.exports = class {
run (client, message, args, data) { //eslint-disable-line no-unused-vars
client.commandLoader.reloadCommands();
client.eventLoader.reloadEventModules();
message.channel.createMessage('All commands and event modules have been reloaded!');
message.channel.send('All commands and event modules have been reloaded!');
}
};