diff --git a/commands/general/tweet.js b/commands/general/tweet.js index 93ec8ca..272f034 100644 --- a/commands/general/tweet.js +++ b/commands/general/tweet.js @@ -1,7 +1,8 @@ const { Command } = require('discord-akairo'); const Twitter = require('twitter-lite'); const rand = require('../../rand.js'); -const filter = require('leo-profanity'); +const Filter = require('bad-words'); +let filter = new Filter(); const { twiConsumer, twiConsumerSecret, twiToken, twiTokenSecret, twiChannel } = require('../../config.json'); const reload = require('auto-reload'); @@ -41,7 +42,6 @@ class tweetCommand extends Command { //Filter out swear word text = filter.clean(text); - console.log(text); text = rand.random(text, message); diff --git a/package.json b/package.json index 4658383..fb29412 100644 --- a/package.json +++ b/package.json @@ -5,6 +5,7 @@ "dependencies": { "@google-cloud/text-to-speech": "^0.4.0", "auto-reload": "^0.1.0", + "bad-words": "^3.0.1", "canvas": "^2.3.0", "discord-akairo": "github:1Computer1/discord-akairo#master", "discord.js": "github:discordjs/discord.js#master",