diff options
author | Chocobozzz <me@florianbigard.com> | 2018-11-14 15:01:28 +0100 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2018-11-14 16:32:27 +0100 |
commit | 5c6d985faeef1d6793d3f44ca6374f1a9b722806 (patch) | |
tree | 567e31a84e721bf762189582f92ac2ec5c402bcc /server/tests/utils/requests | |
parent | df66d81583e07ce049daeeef1edc6a87b57b3684 (diff) | |
download | PeerTube-5c6d985faeef1d6793d3f44ca6374f1a9b722806.tar.gz PeerTube-5c6d985faeef1d6793d3f44ca6374f1a9b722806.tar.zst PeerTube-5c6d985faeef1d6793d3f44ca6374f1a9b722806.zip |
Check activities host
Diffstat (limited to 'server/tests/utils/requests')
-rw-r--r-- | server/tests/utils/requests/activitypub.ts | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/server/tests/utils/requests/activitypub.ts b/server/tests/utils/requests/activitypub.ts index e3e08ce67..96fee60a8 100644 --- a/server/tests/utils/requests/activitypub.ts +++ b/server/tests/utils/requests/activitypub.ts | |||
@@ -3,7 +3,7 @@ import { HTTP_SIGNATURE } from '../../../initializers' | |||
3 | import { buildGlobalHeaders } from '../../../lib/job-queue/handlers/utils/activitypub-http-utils' | 3 | import { buildGlobalHeaders } from '../../../lib/job-queue/handlers/utils/activitypub-http-utils' |
4 | import { activityPubContextify } from '../../../helpers/activitypub' | 4 | import { activityPubContextify } from '../../../helpers/activitypub' |
5 | 5 | ||
6 | function makeAPRequest (url: string, body: any, httpSignature: any, headers: any) { | 6 | function makePOSTAPRequest (url: string, body: any, httpSignature: any, headers: any) { |
7 | const options = { | 7 | const options = { |
8 | method: 'POST', | 8 | method: 'POST', |
9 | uri: url, | 9 | uri: url, |
@@ -34,10 +34,10 @@ async function makeFollowRequest (to: { url: string }, by: { url: string, privat | |||
34 | } | 34 | } |
35 | const headers = buildGlobalHeaders(body) | 35 | const headers = buildGlobalHeaders(body) |
36 | 36 | ||
37 | return makeAPRequest(to.url, body, httpSignature, headers) | 37 | return makePOSTAPRequest(to.url, body, httpSignature, headers) |
38 | } | 38 | } |
39 | 39 | ||
40 | export { | 40 | export { |
41 | makeAPRequest, | 41 | makePOSTAPRequest, |
42 | makeFollowRequest | 42 | makeFollowRequest |
43 | } | 43 | } |