Browse Source

make it work2

pull/1/head
calexil 5 years ago
parent
commit
f6ccede4d2
  1. 6
      bot.js
  2. 5
      bot.js~

6
bot.js

@ -11,6 +11,12 @@ client.on('message', message => { @@ -11,6 +11,12 @@ client.on('message', message => {
}
});
client.on('message2', message => {
if (message.content === 'test') {
message.reply('it worked...');
}
});
// THIS MUST BE THIS WAY
client.login(process.env.BOT_TOKEN);

5
bot.js~

@ -12,10 +12,11 @@ client.on('message', message => { @@ -12,10 +12,11 @@ client.on('message', message => {
});
client.on('message', message => {
if (message.content === 'hello') {
message.reply('hi there, I\'m a dumb bot that doesn\'t work');
if (message.content === 'test') {
message.reply('it worked...');
}
});
// THIS MUST BE THIS WAY
client.login(process.env.BOT_TOKEN);

Loading…
Cancel
Save