From ab9154aa49a132b28b2a938b19c143e1a638b041 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Fri, 24 Oct 2025 13:32:04 -0400 Subject: [PATCH] fix: logic error in out.remove.context --- src/activitypub/out.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/activitypub/out.js b/src/activitypub/out.js index 40d597db51..9c9bdb5dba 100644 --- a/src/activitypub/out.js +++ b/src/activitypub/out.js @@ -376,7 +376,10 @@ Out.move.context = enabledCheck(async (uid, tid) => { const isLocal = id => utils.isNumber(id) && parseInt(id, 10) > 0; if (isLocal(oldCid) && !isLocal(cid)) { // moving to remote/uncategorized return Out.remove.context(uid, tid); - } else if ((isLocal(cid) && !isLocal(oldCid)) || [cid, oldCid].every(!isLocal)) { // stealing or remote-to-remote + } else if ( + (isLocal(cid) && !isLocal(oldCid)) || // stealing, or + [cid, oldCid].every(id => !isLocal(id)) // remote-to-remote + ) { return; }