diff options
Diffstat (limited to 'server/lib/activitypub')
-rw-r--r-- | server/lib/activitypub/url.ts | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/server/lib/activitypub/url.ts b/server/lib/activitypub/url.ts index bb2d4d11e..729bb8dda 100644 --- a/server/lib/activitypub/url.ts +++ b/server/lib/activitypub/url.ts | |||
@@ -3,17 +3,18 @@ import { ActorModel } from '../../models/activitypub/actor' | |||
3 | import { ActorFollowModel } from '../../models/activitypub/actor-follow' | 3 | import { ActorFollowModel } from '../../models/activitypub/actor-follow' |
4 | import { VideoModel } from '../../models/video/video' | 4 | import { VideoModel } from '../../models/video/video' |
5 | import { VideoAbuseModel } from '../../models/video/video-abuse' | 5 | import { VideoAbuseModel } from '../../models/video/video-abuse' |
6 | import { VideoCommentModel } from '../../models/video/video-comment' | ||
6 | 7 | ||
7 | function getVideoActivityPubUrl (video: VideoModel) { | 8 | function getVideoActivityPubUrl (video: VideoModel) { |
8 | return CONFIG.WEBSERVER.URL + '/videos/watch/' + video.uuid | 9 | return CONFIG.WEBSERVER.URL + '/videos/watch/' + video.uuid |
9 | } | 10 | } |
10 | 11 | ||
11 | function getVideoChannelActivityPubUrl (videoChannelUUID: string) { | 12 | function getVideoCommentActivityPubUrl (video: VideoModel, videoComment: VideoCommentModel) { |
12 | return CONFIG.WEBSERVER.URL + '/video-channels/' + videoChannelUUID | 13 | return CONFIG.WEBSERVER.URL + '/videos/watch/' + video.uuid + '#comment-' + videoComment.id |
13 | } | 14 | } |
14 | 15 | ||
15 | function getApplicationActivityPubUrl () { | 16 | function getVideoChannelActivityPubUrl (videoChannelUUID: string) { |
16 | return CONFIG.WEBSERVER.URL + '/application/peertube' | 17 | return CONFIG.WEBSERVER.URL + '/video-channels/' + videoChannelUUID |
17 | } | 18 | } |
18 | 19 | ||
19 | function getAccountActivityPubUrl (accountName: string) { | 20 | function getAccountActivityPubUrl (accountName: string) { |
@@ -63,7 +64,6 @@ function getUndoActivityPubUrl (originalUrl: string) { | |||
63 | } | 64 | } |
64 | 65 | ||
65 | export { | 66 | export { |
66 | getApplicationActivityPubUrl, | ||
67 | getVideoActivityPubUrl, | 67 | getVideoActivityPubUrl, |
68 | getVideoChannelActivityPubUrl, | 68 | getVideoChannelActivityPubUrl, |
69 | getAccountActivityPubUrl, | 69 | getAccountActivityPubUrl, |
@@ -75,5 +75,6 @@ export { | |||
75 | getUndoActivityPubUrl, | 75 | getUndoActivityPubUrl, |
76 | getVideoViewActivityPubUrl, | 76 | getVideoViewActivityPubUrl, |
77 | getVideoLikeActivityPubUrl, | 77 | getVideoLikeActivityPubUrl, |
78 | getVideoDislikeActivityPubUrl | 78 | getVideoDislikeActivityPubUrl, |
79 | getVideoCommentActivityPubUrl | ||
79 | } | 80 | } |