mirror of
https://gitlab.com/soapbox-pub/ditto.git
synced 2025-12-06 11:29:46 +00:00
Don't call ffprobe unless mediaTranscode is enabled
This commit is contained in:
parent
3035ecaca9
commit
c2e6e10a3a
1 changed files with 1 additions and 1 deletions
|
|
@ -44,7 +44,7 @@ export async function uploadFile(
|
||||||
const [baseType] = file.type.split('/');
|
const [baseType] = file.type.split('/');
|
||||||
|
|
||||||
perf.mark('probe-start');
|
perf.mark('probe-start');
|
||||||
const probe = await analyzeFile(file.stream(), { ffprobePath }).catch(() => null);
|
const probe = mediaTranscode ? await analyzeFile(file.stream(), { ffprobePath }).catch(() => null) : null;
|
||||||
const video = probe?.streams.find((stream) => stream.codec_type === 'video');
|
const video = probe?.streams.find((stream) => stream.codec_type === 'video');
|
||||||
perf.mark('probe-end');
|
perf.mark('probe-end');
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue