From 600b1a8622c078b7e7cd9b2d3e7ffdc74db96be0 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Thu, 4 Jul 2024 17:00:14 -0400 Subject: [PATCH] fix: update handling of Announce(Create(Note)) to also handle non-note types --- src/activitypub/inbox.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/activitypub/inbox.js b/src/activitypub/inbox.js index 310f09cd48..a30373209b 100644 --- a/src/activitypub/inbox.js +++ b/src/activitypub/inbox.js @@ -239,8 +239,8 @@ inbox.announce = async (req) => { } } - // Handle case where Announce(Create(Note)) is received - if (object.type === 'Create' && object.object.type === 'Note') { + // Handle case where Announce(Create(Note-ish)) is received + if (object.type === 'Create' && activitypub._constants.acceptedPostTypes.includes(object.object.type)) { pid = object.object.id; } else { pid = object.id;