diff options
Diffstat (limited to 'server/lib/activitypub/share.ts')
-rw-r--r-- | server/lib/activitypub/share.ts | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/server/lib/activitypub/share.ts b/server/lib/activitypub/share.ts index 5e426f5db..1f8a8f3c4 100644 --- a/server/lib/activitypub/share.ts +++ b/server/lib/activitypub/share.ts | |||
@@ -1,7 +1,7 @@ | |||
1 | import { Transaction } from 'sequelize' | 1 | import { Transaction } from 'sequelize' |
2 | import { VideoShareModel } from '../../models/video/video-share' | 2 | import { VideoShareModel } from '../../models/video/video-share' |
3 | import { sendUndoAnnounce, sendVideoAnnounce } from './send' | 3 | import { sendUndoAnnounce, sendVideoAnnounce } from './send' |
4 | import { getVideoAnnounceActivityPubUrl } from './url' | 4 | import { getLocalVideoAnnounceActivityPubUrl } from './url' |
5 | import * as Bluebird from 'bluebird' | 5 | import * as Bluebird from 'bluebird' |
6 | import { doRequest } from '../../helpers/requests' | 6 | import { doRequest } from '../../helpers/requests' |
7 | import { getOrCreateActorAndServerAndModel } from './actor' | 7 | import { getOrCreateActorAndServerAndModel } from './actor' |
@@ -74,7 +74,7 @@ export { | |||
74 | async function shareByServer (video: MVideo, t: Transaction) { | 74 | async function shareByServer (video: MVideo, t: Transaction) { |
75 | const serverActor = await getServerActor() | 75 | const serverActor = await getServerActor() |
76 | 76 | ||
77 | const serverShareUrl = getVideoAnnounceActivityPubUrl(serverActor, video) | 77 | const serverShareUrl = getLocalVideoAnnounceActivityPubUrl(serverActor, video) |
78 | const [ serverShare ] = await VideoShareModel.findOrCreate({ | 78 | const [ serverShare ] = await VideoShareModel.findOrCreate({ |
79 | defaults: { | 79 | defaults: { |
80 | actorId: serverActor.id, | 80 | actorId: serverActor.id, |
@@ -91,7 +91,7 @@ async function shareByServer (video: MVideo, t: Transaction) { | |||
91 | } | 91 | } |
92 | 92 | ||
93 | async function shareByVideoChannel (video: MVideoAccountLight, t: Transaction) { | 93 | async function shareByVideoChannel (video: MVideoAccountLight, t: Transaction) { |
94 | const videoChannelShareUrl = getVideoAnnounceActivityPubUrl(video.VideoChannel.Actor, video) | 94 | const videoChannelShareUrl = getLocalVideoAnnounceActivityPubUrl(video.VideoChannel.Actor, video) |
95 | const [ videoChannelShare ] = await VideoShareModel.findOrCreate({ | 95 | const [ videoChannelShare ] = await VideoShareModel.findOrCreate({ |
96 | defaults: { | 96 | defaults: { |
97 | actorId: video.VideoChannel.actorId, | 97 | actorId: video.VideoChannel.actorId, |