diff options
author | Chocobozzz <me@florianbigard.com> | 2018-08-27 16:23:34 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2018-08-27 16:23:34 +0200 |
commit | 62689b942b71cd1dd0d050c6ed05f884a0b325c2 (patch) | |
tree | c45c35d35d7a3e32621fba06edc63646930c8efd /server/models/video/video-caption.ts | |
parent | 84b6dbcc6e8654f39ec798905e1151ba915cd1aa (diff) | |
download | PeerTube-62689b942b71cd1dd0d050c6ed05f884a0b325c2.tar.gz PeerTube-62689b942b71cd1dd0d050c6ed05f884a0b325c2.tar.zst PeerTube-62689b942b71cd1dd0d050c6ed05f884a0b325c2.zip |
Correctly migrate to fs-extra
Diffstat (limited to 'server/models/video/video-caption.ts')
-rw-r--r-- | server/models/video/video-caption.ts | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/server/models/video/video-caption.ts b/server/models/video/video-caption.ts index 3593646a2..10ef46c14 100644 --- a/server/models/video/video-caption.ts +++ b/server/models/video/video-caption.ts | |||
@@ -19,7 +19,7 @@ import { VideoCaption } from '../../../shared/models/videos/caption/video-captio | |||
19 | import { CONFIG, STATIC_PATHS, VIDEO_LANGUAGES } from '../../initializers' | 19 | import { CONFIG, STATIC_PATHS, VIDEO_LANGUAGES } from '../../initializers' |
20 | import { join } from 'path' | 20 | import { join } from 'path' |
21 | import { logger } from '../../helpers/logger' | 21 | import { logger } from '../../helpers/logger' |
22 | import { unlinkPromise } from '../../helpers/core-utils' | 22 | import { remove } from 'fs-extra' |
23 | 23 | ||
24 | export enum ScopeNames { | 24 | export enum ScopeNames { |
25 | WITH_VIDEO_UUID_AND_REMOTE = 'WITH_VIDEO_UUID_AND_REMOTE' | 25 | WITH_VIDEO_UUID_AND_REMOTE = 'WITH_VIDEO_UUID_AND_REMOTE' |
@@ -172,6 +172,6 @@ export class VideoCaptionModel extends Model<VideoCaptionModel> { | |||
172 | } | 172 | } |
173 | 173 | ||
174 | removeCaptionFile () { | 174 | removeCaptionFile () { |
175 | return unlinkPromise(CONFIG.STORAGE.CAPTIONS_DIR + this.getCaptionName()) | 175 | return remove(CONFIG.STORAGE.CAPTIONS_DIR + this.getCaptionName()) |
176 | } | 176 | } |
177 | } | 177 | } |