Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
const ignoreExtraTriggeredPipelines = pipelineTuples.filter((t) => {
// empty event is not created when it is triggered by extra triggers (e.g. ~tag, ~release)
if (EXTRA_TRIGGERS.test(t.startFrom) && !hasTriggeredJob(t.pipeline, t.startFrom)) {
logger.warn(`Event not created: there are no jobs triggered by ${t.startFrom}`);
return false;
}
return true;
});