Display ffmpeg output errors

pull/364/head
Chocobozzz 2018-03-20 08:21:30 +01:00
parent 749cedcc60
commit 747b29900d
No known key found for this signature in database
GPG Key ID: 583A612D890159BE
1 changed files with 7 additions and 3 deletions

View File

@ -102,9 +102,13 @@ function transcode (options: TranscodeOptions) {
command = command.size(size)
}
command.on('error', rej)
.on('end', res)
.run()
command
.on('error', (err, stdout, stderr) => {
logger.error('Error in transcoding job.', { stdout, stderr })
return rej(err)
})
.on('end', res)
.run()
})
}