aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/lib/job-queue/handlers/utils
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2020-03-12 14:14:00 +0100
committerChocobozzz <me@florianbigard.com>2020-03-12 14:14:11 +0100
commit84ebcf345cb82b254853c03c142f7c304fb072dd (patch)
tree91dac605f98dd606426dd9e143706a08baa00b6e /server/lib/job-queue/handlers/utils
parent8227643bce85747953eb43ddc553f14d29bc475f (diff)
downloadPeerTube-84ebcf345cb82b254853c03c142f7c304fb072dd.tar.gz
PeerTube-84ebcf345cb82b254853c03c142f7c304fb072dd.tar.zst
PeerTube-84ebcf345cb82b254853c03c142f7c304fb072dd.zip
Fix federation with pleroma
Diffstat (limited to 'server/lib/job-queue/handlers/utils')
-rw-r--r--server/lib/job-queue/handlers/utils/activitypub-http-utils.ts6
1 files changed, 4 insertions, 2 deletions
diff --git a/server/lib/job-queue/handlers/utils/activitypub-http-utils.ts b/server/lib/job-queue/handlers/utils/activitypub-http-utils.ts
index 54b35840d..258ffabee 100644
--- a/server/lib/job-queue/handlers/utils/activitypub-http-utils.ts
+++ b/server/lib/job-queue/handlers/utils/activitypub-http-utils.ts
@@ -2,7 +2,7 @@ import { buildSignedActivity, ContextType } from '../../../../helpers/activitypu
2import { getServerActor } from '../../../../helpers/utils' 2import { getServerActor } from '../../../../helpers/utils'
3import { ActorModel } from '../../../../models/activitypub/actor' 3import { ActorModel } from '../../../../models/activitypub/actor'
4import { sha256 } from '../../../../helpers/core-utils' 4import { sha256 } from '../../../../helpers/core-utils'
5import { HTTP_SIGNATURE } from '../../../../initializers/constants' 5import { ACTIVITY_PUB, HTTP_SIGNATURE } from '../../../../initializers/constants'
6import { MActor } from '../../../../typings/models' 6import { MActor } from '../../../../typings/models'
7 7
8type Payload = { body: any, contextType?: ContextType, signatureActorId?: number } 8type Payload = { body: any, contextType?: ContextType, signatureActorId?: number }
@@ -42,7 +42,9 @@ async function buildSignedRequestOptions (payload: Payload) {
42 42
43function buildGlobalHeaders (body: any) { 43function buildGlobalHeaders (body: any) {
44 return { 44 return {
45 Digest: buildDigest(body) 45 'Digest': buildDigest(body),
46 'Content-Type': 'application/activity+json',
47 'Accept': ACTIVITY_PUB.ACCEPT_HEADER
46 } 48 }
47} 49}
48 50