From bb0360bf018286283389edfaef071896c35aa6c3 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Tue, 11 Jun 2024 14:17:36 -0400 Subject: [PATCH] chore: commenting out logic that drops requests if the id has already been seen, due to a regression in interoperability between NodeBB instances --- src/middleware/activitypub.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/middleware/activitypub.js b/src/middleware/activitypub.js index 82bc88cfb7..1080519183 100644 --- a/src/middleware/activitypub.js +++ b/src/middleware/activitypub.js @@ -40,11 +40,11 @@ middleware.validate = async function (req, res, next) { // winston.verbose('[middleware/activitypub] Request body check passed.'); // History check - const seen = await db.isSortedSetMember('activities:datetime', req.body.id); - if (seen) { - // winston.verbose(`[middleware/activitypub] Activity already seen, ignoring (${req.body.id}).`); - return res.sendStatus(200); - } + // const seen = await db.isSortedSetMember('activities:datetime', req.body.id); + // if (seen) { + // // winston.verbose(`[middleware/activitypub] Activity already seen, ignoring (${req.body.id}).`); + // return res.sendStatus(200); + // } // Checks the validity of the incoming payload against the sender and rejects on failure const verified = await activitypub.verify(req);