forked from Supositware/Haha-Yes
Fixed reaction
This commit is contained in:
parent
a0aeb7cdcd
commit
f1f774736d
2 changed files with 12 additions and 8 deletions
11
index.js
11
index.js
|
@ -66,13 +66,16 @@ client.registry
|
||||||
// Auto respond to messages
|
// Auto respond to messages
|
||||||
client.on("message", async (message) => {
|
client.on("message", async (message) => {
|
||||||
let message_content = message.content.toLowerCase();
|
let message_content = message.content.toLowerCase();
|
||||||
if(responseObject[message_content]) {
|
if(responseObject[message_content] && reactObject[message_content]) {
|
||||||
message.channel.send(responseObject[message_content]);
|
message.channel.send(responseObject[message_content]);
|
||||||
};
|
|
||||||
|
|
||||||
if(reactObject[message_content]) {
|
|
||||||
message.react(reactObject[message_content]);
|
message.react(reactObject[message_content]);
|
||||||
}
|
}
|
||||||
|
else if(reactObject[message_content]) {
|
||||||
|
message.react(reactObject[message_content]);
|
||||||
|
}
|
||||||
|
else if(responseObject[message_content]) {
|
||||||
|
message.channel.send(responseObject[message_content]);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
client.on('error', console.error);
|
client.on('error', console.error);
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
{
|
{
|
||||||
"like if owned": "👍"
|
"like if owned": "👍",
|
||||||
|
"fortnite": "🤦"
|
||||||
}
|
}
|
Loading…
Reference in a new issue