mirror of
https://github.com/Viren070/AIOStreams.git
synced 2025-12-01 23:14:04 +01:00
fix: filter out null tests
This commit is contained in:
@@ -356,8 +356,8 @@ export class AIOStreams {
|
||||
}
|
||||
|
||||
// generate array of excludeTests. for each regex, only add to array if the filename or indexers are defined
|
||||
const excludeTests = [];
|
||||
const requiredTests = [];
|
||||
let excludeTests = [];
|
||||
let requiredTests = [];
|
||||
|
||||
if (parsedStream.filename) {
|
||||
excludeTests.push(
|
||||
@@ -396,6 +396,10 @@ export class AIOStreams {
|
||||
);
|
||||
}
|
||||
|
||||
// filter out any null values as these are when the regex is not defined
|
||||
excludeTests = excludeTests.filter((test) => test !== null);
|
||||
requiredTests = requiredTests.filter((test) => test !== null);
|
||||
|
||||
if (excludeTests.length > 0 && excludeTests.some((test) => test)) {
|
||||
skipReasons.excludeRegex++;
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user