From f2eec884ec067b04bc267ee5d4ab1ac65d1aee43 Mon Sep 17 00:00:00 2001 From: Tagadda <36127788+Tagadda@users.noreply.github.com> Date: Wed, 13 Jun 2018 05:23:54 +0200 Subject: [PATCH] Prevent follow bots --- index.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/index.js b/index.js index a7d57b2..d7ebebf 100644 --- a/index.js +++ b/index.js @@ -49,6 +49,12 @@ client.on('update', (msg) => { return; } + // Don't follow other bots + if(msg.account.bot === true) { + console.log("BOT: " + acct); + return; + } + // Respect #nobot if (striptags(msg.account.note).match(/#nobot/i)) { client.mute_user(id); -- GitLab