mirror of
https://github.com/gabehf/Tdarr_Plugins.git
synced 2026-03-09 15:38:19 -07:00
Check mediaInfo properties
This commit is contained in:
parent
1e5d6b8014
commit
0b11e8ad75
2 changed files with 28 additions and 1 deletions
|
|
@ -76,7 +76,10 @@ const plugin = (file, librarySettings, inputs, otherArguments) => {
|
|||
let streamToRemove = false;
|
||||
for (let i = 0; i < file.ffProbeData.streams.length; i += 1) {
|
||||
try {
|
||||
if (valuesToRemove.includes(String(file.ffProbeData.streams[i][propertyToCheck]))) {
|
||||
if (
|
||||
valuesToRemove.includes(String(file.ffProbeData.streams[i][propertyToCheck]))
|
||||
|| valuesToRemove.includes(String(file.mediaInfo.track[i + 1][propertyToCheck]))
|
||||
) {
|
||||
response.preset += ` -map -0:${i} `;
|
||||
response.infoLog += ` Removing stream ${i} which is has ${propertyToCheck}`
|
||||
+ ` of ${file.ffProbeData.streams[i][propertyToCheck]} \n`;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue