add embed to ping.js & pass in args, cfg to commands

This commit is contained in:
2021-08-23 17:30:41 +02:00
parent f1bec2d133
commit 379e6a1108
2 changed files with 9 additions and 2 deletions

View File

@@ -1,6 +1,13 @@
module.exports = {
name: 'ping',
execute(msg) {
execute(msg, args, cfg) {
const pingembed = {
color: cfg.hexBlue,
title: `ping`,
timestamp: new Date(),
description: `Pong! ${Date.now() - msg.createdTimestamp}`,
};
msg.channel.send(`pong`);
msg.channel.send({ embeds: [pingembed] });
},
};