forked from Supositware/Haha-Yes
some spam prevention
This commit is contained in:
parent
70d1991b25
commit
cebc55cd05
1 changed files with 6 additions and 0 deletions
|
@ -38,6 +38,12 @@ class tweetCommand extends Command {
|
|||
filter.removeWords(...uncensor);
|
||||
*/
|
||||
|
||||
// Don't let account new account use this command to prevent spam
|
||||
let date = new Date();
|
||||
if (message.author.createdAt > date.setDate(date.getDate() - 7)) {
|
||||
return message.channel.send('Your account is too new to be able to use this command!');
|
||||
}
|
||||
|
||||
const blacklist = reload('../../json/twiBlacklist.json');
|
||||
|
||||
if (blacklist.includes(message.author.id)) {
|
||||
|
|
Loading…
Reference in a new issue