From cc54931d4e1808828a751d14c2279e3e502cfb3d Mon Sep 17 00:00:00 2001 From: GramingFoxTeam Date: Fri, 18 Nov 2022 12:47:14 +0300 Subject: [PATCH] fix(reddit-bot): dont check for item creation date --- bots/reddit/index.js | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/bots/reddit/index.js b/bots/reddit/index.js index d28bbe8..bd422bc 100644 --- a/bots/reddit/index.js +++ b/bots/reddit/index.js @@ -38,7 +38,6 @@ for (const file of commandFiles) { } } -const BOT_START = Date.now() / 1000; global.checkedItems = []; const args = { @@ -52,17 +51,15 @@ const comments = new CommentStream(global.client, args); const posts = new SubmissionStream(global.client, args); comments.on('item', async (item) => { - if (item.created_utc < BOT_START) return; await handleItem(item, false); }); posts.on('item', async (item) => { - //if (item.created_utc < BOT_START) return; await handleItem(item, true); }); async function handleItem(item, isPost) { - // The "skill issue (refresh) incident." + // The "skill issue (refresh)" incident. if (item.author.name === global.config.reddit.username) return; if (global.checkedItems.includes(item.id)) return;