From 40396fda669a9b27485335afa51b1bba5b211da4 Mon Sep 17 00:00:00 2001 From: Supositware Date: Wed, 2 Jan 2019 21:46:12 +0100 Subject: [PATCH] Change for Akairo V8 --- listeners/commandblocked.js | 2 +- listeners/guildCreate.js | 2 +- listeners/guildDelete.js | 2 +- listeners/message.js | 14 +++++++------- listeners/messageReactionAdd.js | 2 +- 5 files changed, 11 insertions(+), 11 deletions(-) diff --git a/listeners/commandblocked.js b/listeners/commandblocked.js index fc92a05..6fed8c7 100644 --- a/listeners/commandblocked.js +++ b/listeners/commandblocked.js @@ -4,7 +4,7 @@ class CommandBlockedListener extends Listener { constructor() { super('commandBlocked', { emitter: 'commandHandler', - eventName: 'commandBlocked' + event: 'commandBlocked' }); } diff --git a/listeners/guildCreate.js b/listeners/guildCreate.js index c20b9f2..aba2096 100644 --- a/listeners/guildCreate.js +++ b/listeners/guildCreate.js @@ -7,7 +7,7 @@ class guildCreateListener extends Listener { constructor() { super('guildCreate', { emitter: 'client', - eventName: 'guildCreate' + event: 'guildCreate' }); } diff --git a/listeners/guildDelete.js b/listeners/guildDelete.js index c6ba974..7c993c5 100644 --- a/listeners/guildDelete.js +++ b/listeners/guildDelete.js @@ -7,7 +7,7 @@ class guildCreateListener extends Listener { constructor() { super('guildDelete', { emitter: 'client', - eventName: 'guildDelete' + event: 'guildDelete' }); } diff --git a/listeners/message.js b/listeners/message.js index cd855d6..2085e02 100644 --- a/listeners/message.js +++ b/listeners/message.js @@ -4,11 +4,11 @@ const reactObject = require('../json/react.json'); const imgResponseObject = require('../json/imgreply.json'); const reload = require('auto-reload'); -class MessageListener extends Listener { +class messageListener extends Listener { constructor() { super('message', { emitter: 'client', - eventName: 'message' + event: 'message' }); } @@ -16,14 +16,14 @@ class MessageListener extends Listener { let autoresponse = reload('../json/autoresponse.json'); let message_content = message.content.toLowerCase(); let customresponse = reload(`../tag/${message.guild.id}.json`); - + if (message.author.bot) return; { - + // User autoresponse if(customresponse[message_content]) { message.channel.send(customresponse[message_content]); } - + // If autoresponse is enable send the response if(autoresponse[message.channel.id] == 'enable') { // Reply with images as attachement @@ -44,9 +44,9 @@ class MessageListener extends Listener { } else if (message_content.includes('jeff')) { message.react('496028845967802378'); } - } + } } } } -module.exports = MessageListener; \ No newline at end of file +module.exports = messageListener; \ No newline at end of file diff --git a/listeners/messageReactionAdd.js b/listeners/messageReactionAdd.js index 4c2e247..a1c8257 100644 --- a/listeners/messageReactionAdd.js +++ b/listeners/messageReactionAdd.js @@ -6,7 +6,7 @@ class MessageReactionAddListener extends Listener { constructor() { super('messagereactionadd', { emitter: 'client', - eventName: 'messageReactionAdd' + event: 'messageReactionAdd' }); }