diff options
Diffstat (limited to 'server/lib/activitypub/videos.ts')
-rw-r--r-- | server/lib/activitypub/videos.ts | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/server/lib/activitypub/videos.ts b/server/lib/activitypub/videos.ts index 91231a187..48c0e0a5c 100644 --- a/server/lib/activitypub/videos.ts +++ b/server/lib/activitypub/videos.ts | |||
@@ -354,11 +354,11 @@ async function refreshVideoIfNeeded (options: { | |||
354 | syncParam: SyncParam, | 354 | syncParam: SyncParam, |
355 | refreshViews: boolean | 355 | refreshViews: boolean |
356 | }): Promise<VideoModel> { | 356 | }): Promise<VideoModel> { |
357 | if (!options.video.isOutdated()) return options.video | ||
358 | |||
357 | // We need more attributes if the argument video was fetched with not enough joints | 359 | // We need more attributes if the argument video was fetched with not enough joints |
358 | const video = options.fetchedType === 'all' ? options.video : await VideoModel.loadByUrlAndPopulateAccount(options.video.url) | 360 | const video = options.fetchedType === 'all' ? options.video : await VideoModel.loadByUrlAndPopulateAccount(options.video.url) |
359 | 361 | ||
360 | if (!video.isOutdated()) return video | ||
361 | |||
362 | try { | 362 | try { |
363 | const { response, videoObject } = await fetchRemoteVideo(video.url) | 363 | const { response, videoObject } = await fetchRemoteVideo(video.url) |
364 | if (response.statusCode === 404) { | 364 | if (response.statusCode === 404) { |