Skip to content

Node.js based forum software built for the modern web

feat: activitypub.get; allow the passing-in of custom headers via existing `options` parameter

Julian Lamda25fd21ea54
diff --git a/src/activitypub/index.js b/src/activitypub/index.js
index 8854e26edf..1d37f2f546 100644
--- a/src/activitypub/index.js
+++ b/src/activitypub/index.js
@@ -269,6 +269,7 @@ ActivityPub.get = async (type, id, uri, options) => {
const { response, body } = await request.get(uri, {
headers: {
...headers,
+ ...options.headers,
Accept: 'application/ld+json; profile="https://www.w3.org/ns/activitystreams"',
},
timeout: 5000,