diff options
author | Chocobozzz <florian.bigard@gmail.com> | 2017-11-24 13:41:10 +0100 |
---|---|---|
committer | Chocobozzz <florian.bigard@gmail.com> | 2017-11-27 19:40:53 +0100 |
commit | 63c93323ecdeaa4b6183d75dd3f13469e1ef3ebd (patch) | |
tree | 3ee4b351025d4b19f6e880754df44fa7605b683d /server/lib/activitypub/process/process-add.ts | |
parent | d4f1e94c89336255537b0b82913591f00e716201 (diff) | |
download | PeerTube-63c93323ecdeaa4b6183d75dd3f13469e1ef3ebd.tar.gz PeerTube-63c93323ecdeaa4b6183d75dd3f13469e1ef3ebd.tar.zst PeerTube-63c93323ecdeaa4b6183d75dd3f13469e1ef3ebd.zip |
Correctly forward like/dislikes and undo
Diffstat (limited to 'server/lib/activitypub/process/process-add.ts')
-rw-r--r-- | server/lib/activitypub/process/process-add.ts | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/server/lib/activitypub/process/process-add.ts b/server/lib/activitypub/process/process-add.ts index 433e68eb6..98280b9f0 100644 --- a/server/lib/activitypub/process/process-add.ts +++ b/server/lib/activitypub/process/process-add.ts | |||
@@ -76,7 +76,7 @@ function addRemoteVideo (account: AccountInstance, | |||
76 | if (videoChannel.Account.id !== account.id) throw new Error('Video channel is not owned by this account.') | 76 | if (videoChannel.Account.id !== account.id) throw new Error('Video channel is not owned by this account.') |
77 | 77 | ||
78 | const videoFromDatabase = await db.Video.loadByUUIDOrURL(videoToCreateData.uuid, videoToCreateData.id, t) | 78 | const videoFromDatabase = await db.Video.loadByUUIDOrURL(videoToCreateData.uuid, videoToCreateData.id, t) |
79 | if (videoFromDatabase) throw new Error('Video with this UUID/Url already exists.') | 79 | if (videoFromDatabase) return videoFromDatabase |
80 | 80 | ||
81 | const videoData = await videoActivityObjectToDBAttributes(videoChannel, videoToCreateData, activity.to, activity.cc) | 81 | const videoData = await videoActivityObjectToDBAttributes(videoChannel, videoToCreateData, activity.to, activity.cc) |
82 | const video = db.Video.build(videoData) | 82 | const video = db.Video.build(videoData) |