diff options
Diffstat (limited to 'server/lib/activitypub/playlist.ts')
-rw-r--r-- | server/lib/activitypub/playlist.ts | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/server/lib/activitypub/playlist.ts b/server/lib/activitypub/playlist.ts index 7166c68a6..8fe6e79f2 100644 --- a/server/lib/activitypub/playlist.ts +++ b/server/lib/activitypub/playlist.ts | |||
@@ -18,7 +18,7 @@ import { FilteredModelAttributes } from '../../types/sequelize' | |||
18 | import { createPlaylistMiniatureFromUrl } from '../thumbnail' | 18 | import { createPlaylistMiniatureFromUrl } from '../thumbnail' |
19 | import { getOrCreateActorAndServerAndModel } from './actor' | 19 | import { getOrCreateActorAndServerAndModel } from './actor' |
20 | import { crawlCollectionPage } from './crawl' | 20 | import { crawlCollectionPage } from './crawl' |
21 | import { getOrCreateVideoAndAccountAndChannel } from './videos' | 21 | import { getOrCreateAPVideo } from './videos' |
22 | 22 | ||
23 | function playlistObjectToDBAttributes (playlistObject: PlaylistObject, byAccount: MAccountId, to: string[]) { | 23 | function playlistObjectToDBAttributes (playlistObject: PlaylistObject, byAccount: MAccountId, to: string[]) { |
24 | const privacy = to.includes(ACTIVITY_PUB.PUBLIC) | 24 | const privacy = to.includes(ACTIVITY_PUB.PUBLIC) |
@@ -169,7 +169,7 @@ async function resetVideoPlaylistElements (elementUrls: string[], playlist: MVid | |||
169 | throw new Error(`Playlist element url ${elementUrl} host is different from the AP object id ${body.id}`) | 169 | throw new Error(`Playlist element url ${elementUrl} host is different from the AP object id ${body.id}`) |
170 | } | 170 | } |
171 | 171 | ||
172 | const { video } = await getOrCreateVideoAndAccountAndChannel({ videoObject: { id: body.url }, fetchType: 'only-video' }) | 172 | const { video } = await getOrCreateAPVideo({ videoObject: { id: body.url }, fetchType: 'only-video' }) |
173 | 173 | ||
174 | elementsToCreate.push(playlistElementObjectToDBAttributes(body, playlist, video)) | 174 | elementsToCreate.push(playlistElementObjectToDBAttributes(body, playlist, video)) |
175 | } catch (err) { | 175 | } catch (err) { |