From 10e4d57996d6e36f72f7da3eabe75e16ad262b44 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Thu, 12 Mar 2026 11:36:06 -0400 Subject: [PATCH] fix: skip AP cache on context processing methods --- src/activitypub/contexts.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/activitypub/contexts.js b/src/activitypub/contexts.js index 8335ae7cc4..fa4709158a 100644 --- a/src/activitypub/contexts.js +++ b/src/activitypub/contexts.js @@ -25,7 +25,7 @@ Contexts.get = async (uid, id) => { } try { - ({ id, type, context } = await activitypub.get('uid', uid, id, { headers })); + ({ id, type, context } = await activitypub.get('uid', uid, id, { headers, cache: false })); if (activitypub._constants.acceptable.contextTypes.has(type)) { // is context activitypub.helpers.log(`[activitypub/context] ${id} is the context.`); return { context: id }; @@ -35,7 +35,7 @@ Contexts.get = async (uid, id) => { } // context provided; try to resolve it. - ({ type } = await activitypub.get('uid', uid, context)); + ({ type } = await activitypub.get('uid', uid, context, { cache: false })); } catch (e) { if (e.code === 'ap_get_304') { activitypub.helpers.log(`[activitypub/context] ${id} context unchanged.`); @@ -65,7 +65,7 @@ Contexts.getItems = async (uid, id, options) => { } else { activitypub.helpers.log(`[activitypub/context] Retrieving context/page ${id}`); try { - object = await activitypub.get('uid', uid, id); + object = await activitypub.get('uid', uid, id, { cache: false }); } catch (e) { return false; }