diff options
author | Chocobozzz <me@florianbigard.com> | 2019-01-15 11:14:12 +0100 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2019-01-15 14:45:09 +0100 |
commit | 848f499def54db2dd36437ef0dfb74dd5041c23b (patch) | |
tree | 13e6fcd30e3ce5306d5999fc91561af54d9fd20e /server/helpers/activitypub.ts | |
parent | 44b9c0ba31c4a97e3d874f33226ad935c3a90dd5 (diff) | |
download | PeerTube-848f499def54db2dd36437ef0dfb74dd5041c23b.tar.gz PeerTube-848f499def54db2dd36437ef0dfb74dd5041c23b.tar.zst PeerTube-848f499def54db2dd36437ef0dfb74dd5041c23b.zip |
Prepare Dislike/Flag/View fixes
For now we Create these activities, but we should just send them
directly.
This fix handles correctly direct Dislikes/Flags/Views, we'll implement
the sending correctly these activities in the next peertube version
Diffstat (limited to 'server/helpers/activitypub.ts')
-rw-r--r-- | server/helpers/activitypub.ts | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/server/helpers/activitypub.ts b/server/helpers/activitypub.ts index 79b76fa0b..f1430055f 100644 --- a/server/helpers/activitypub.ts +++ b/server/helpers/activitypub.ts | |||
@@ -106,7 +106,7 @@ function buildSignedActivity (byActor: ActorModel, data: Object) { | |||
106 | return signJsonLDObject(byActor, activity) as Promise<Activity> | 106 | return signJsonLDObject(byActor, activity) as Promise<Activity> |
107 | } | 107 | } |
108 | 108 | ||
109 | function getAPUrl (activity: string | { id: string }) { | 109 | function getAPId (activity: string | { id: string }) { |
110 | if (typeof activity === 'string') return activity | 110 | if (typeof activity === 'string') return activity |
111 | 111 | ||
112 | return activity.id | 112 | return activity.id |
@@ -123,7 +123,7 @@ function checkUrlsSameHost (url1: string, url2: string) { | |||
123 | 123 | ||
124 | export { | 124 | export { |
125 | checkUrlsSameHost, | 125 | checkUrlsSameHost, |
126 | getAPUrl, | 126 | getAPId, |
127 | activityPubContextify, | 127 | activityPubContextify, |
128 | activityPubCollectionPagination, | 128 | activityPubCollectionPagination, |
129 | buildSignedActivity | 129 | buildSignedActivity |