diff options
Diffstat (limited to 'server/initializers/migrations/0075-video-resolutions.ts')
-rw-r--r-- | server/initializers/migrations/0075-video-resolutions.ts | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/server/initializers/migrations/0075-video-resolutions.ts b/server/initializers/migrations/0075-video-resolutions.ts index 6e8e47acb..8cd47496e 100644 --- a/server/initializers/migrations/0075-video-resolutions.ts +++ b/server/initializers/migrations/0075-video-resolutions.ts | |||
@@ -1,8 +1,8 @@ | |||
1 | import * as Sequelize from 'sequelize' | 1 | import { readdir, rename } from 'fs-extra' |
2 | import { join } from 'path' | 2 | import { join } from 'path' |
3 | import * as Sequelize from 'sequelize' | ||
4 | import { getVideoStreamDimensionsInfo } from '../../helpers/ffmpeg/ffprobe-utils' | ||
3 | import { CONFIG } from '../../initializers/config' | 5 | import { CONFIG } from '../../initializers/config' |
4 | import { getVideoFileResolution } from '../../helpers/ffprobe-utils' | ||
5 | import { readdir, rename } from 'fs-extra' | ||
6 | 6 | ||
7 | function up (utils: { | 7 | function up (utils: { |
8 | transaction: Sequelize.Transaction | 8 | transaction: Sequelize.Transaction |
@@ -26,7 +26,7 @@ function up (utils: { | |||
26 | const uuid = matches[1] | 26 | const uuid = matches[1] |
27 | const ext = matches[2] | 27 | const ext = matches[2] |
28 | 28 | ||
29 | const p = getVideoFileResolution(join(videoFileDir, videoFile)) | 29 | const p = getVideoStreamDimensionsInfo(join(videoFileDir, videoFile)) |
30 | .then(async ({ resolution }) => { | 30 | .then(async ({ resolution }) => { |
31 | const oldTorrentName = uuid + '.torrent' | 31 | const oldTorrentName = uuid + '.torrent' |
32 | const newTorrentName = uuid + '-' + resolution + '.torrent' | 32 | const newTorrentName = uuid + '-' + resolution + '.torrent' |