Compare commits

...

2 Commits

Author SHA1 Message Date
9c60d80bbd Ensure only DTS-HD MA is picked up
Using 'codec_name' would otherwise select anything with DTS, regardless if lossless or lossy
2024-04-27 21:28:16 +00:00
45da0baf90 Only remove SRTs with matching filename 2024-04-27 21:21:22 +00:00
2 changed files with 4 additions and 2 deletions

View File

@ -153,9 +153,11 @@ const details = () => ({
if (ffmpegSubs.length > 0) { if (ffmpegSubs.length > 0) {
let subName = removeMKV(otherArguments.originalLibraryFile.meta.FileName)
response.infoLog += '☒ Changes are required! \n Extracting SRT files'; response.infoLog += '☒ Changes are required! \n Extracting SRT files';
require("child_process").execSync(`rm -rf ${otherArguments.originalLibraryFile.meta.Directory}/*.srt`) require("child_process").execSync(`rm -rf "${otherArguments.originalLibraryFile.meta.Directory}/${subName}*.srt`)
response.FFmpegMode = true; response.FFmpegMode = true;

View File

@ -291,7 +291,7 @@ const response = {
} }
// Identify if stream is DTS-HD MA // Identify if stream is DTS-HD MA
if (file.ffProbeData.streams[i].codec_name.toLowerCase() === 'dts') { if (file.ffProbeData.streams[i].profile.toLowerCase() === 'dts-hd ma') {
// Check if DTS-HD MA has already been handled by a previous run // Check if DTS-HD MA has already been handled by a previous run
// Assume that it will be the second stream (first audio stream) - it should be, if already handled // Assume that it will be the second stream (first audio stream) - it should be, if already handled