diff options
Diffstat (limited to 'server/lib/files-cache/videos-caption-cache.ts')
-rw-r--r-- | server/lib/files-cache/videos-caption-cache.ts | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/server/lib/files-cache/videos-caption-cache.ts b/server/lib/files-cache/videos-caption-cache.ts index 305e39c35..440c3fde8 100644 --- a/server/lib/files-cache/videos-caption-cache.ts +++ b/server/lib/files-cache/videos-caption-cache.ts | |||
@@ -5,6 +5,7 @@ import { VideoCaptionModel } from '../../models/video/video-caption' | |||
5 | import { AbstractVideoStaticFileCache } from './abstract-video-static-file-cache' | 5 | import { AbstractVideoStaticFileCache } from './abstract-video-static-file-cache' |
6 | import { CONFIG } from '../../initializers/config' | 6 | import { CONFIG } from '../../initializers/config' |
7 | import { logger } from '../../helpers/logger' | 7 | import { logger } from '../../helpers/logger' |
8 | import { fetchRemoteVideoStaticFile } from '../activitypub' | ||
8 | 9 | ||
9 | type GetPathParam = { videoId: string, language: string } | 10 | type GetPathParam = { videoId: string, language: string } |
10 | 11 | ||
@@ -49,9 +50,9 @@ class VideosCaptionCache extends AbstractVideoStaticFileCache <GetPathParam> { | |||
49 | const remoteStaticPath = videoCaption.getCaptionStaticPath() | 50 | const remoteStaticPath = videoCaption.getCaptionStaticPath() |
50 | const destPath = join(FILES_CACHE.VIDEO_CAPTIONS.DIRECTORY, videoCaption.getCaptionName()) | 51 | const destPath = join(FILES_CACHE.VIDEO_CAPTIONS.DIRECTORY, videoCaption.getCaptionName()) |
51 | 52 | ||
52 | const path = await this.saveRemoteVideoFileAndReturnPath(video, remoteStaticPath, destPath) | 53 | await fetchRemoteVideoStaticFile(video, remoteStaticPath, destPath) |
53 | 54 | ||
54 | return { isOwned: false, path } | 55 | return { isOwned: false, path: destPath } |
55 | } | 56 | } |
56 | } | 57 | } |
57 | 58 | ||