node-sarif-builder
Advanced tools
Comparing version 0.1.2-alpha202201102239.0 to 0.1.2-alpha202201102248.0
@@ -54,3 +54,3 @@ "use strict"; | ||
// Add result to driver artifact only if not existing | ||
run.artifacts.push(location.physicalLocation.artifactLocation); | ||
run.artifacts.push({ location: { uri: location.physicalLocation.artifactLocation.uri } }); | ||
} | ||
@@ -60,10 +60,10 @@ } | ||
// Build artifacts indexes | ||
const artifactIndexes = Object.fromEntries(run.artifacts.map((artifact, index) => { | ||
const artifactIndexes = run.artifacts.map((artifact) => { | ||
var _a; | ||
return [(_a = artifact === null || artifact === void 0 ? void 0 : artifact.location) === null || _a === void 0 ? void 0 : _a.uri, index]; | ||
})); | ||
return (_a = artifact === null || artifact === void 0 ? void 0 : artifact.location) === null || _a === void 0 ? void 0 : _a.uri; | ||
}); | ||
// Build rules indexes | ||
const rulesIndexes = Object.fromEntries((((_d = (_c = run === null || run === void 0 ? void 0 : run.tool) === null || _c === void 0 ? void 0 : _c.driver) === null || _d === void 0 ? void 0 : _d.rules) || []).map((rule, index) => { | ||
return [rule.id, index]; | ||
})); | ||
const rulesIndexes = (((_d = (_c = run === null || run === void 0 ? void 0 : run.tool) === null || _c === void 0 ? void 0 : _c.driver) === null || _d === void 0 ? void 0 : _d.rules) || []).map((rule) => { | ||
return rule.id; | ||
}); | ||
// Update index in results with computed values | ||
@@ -70,0 +70,0 @@ run.results = run.results.map(result => { |
{ | ||
"name": "node-sarif-builder", | ||
"version": "0.1.2-alpha202201102239.0", | ||
"version": "0.1.2-alpha202201102248.0", | ||
"description": "Module to help building SARIF log files", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
@@ -65,3 +65,3 @@ import * as fs from 'fs-extra'; | ||
// Add result to driver artifact only if not existing | ||
run.artifacts.push(location.physicalLocation.artifactLocation); | ||
run.artifacts.push({ location: { uri: location.physicalLocation.artifactLocation.uri } }); | ||
} | ||
@@ -71,9 +71,9 @@ } | ||
// Build artifacts indexes | ||
const artifactIndexes = Object.fromEntries(run.artifacts.map((artifact, index) => { | ||
return [artifact?.location?.uri, index]; | ||
})); | ||
const artifactIndexes = run.artifacts.map((artifact) => { | ||
return artifact?.location?.uri; | ||
}); | ||
// Build rules indexes | ||
const rulesIndexes = Object.fromEntries((run?.tool?.driver?.rules || []).map((rule, index) => { | ||
return [rule.id, index]; | ||
})); | ||
const rulesIndexes = (run?.tool?.driver?.rules || []).map((rule) => { | ||
return rule.id; | ||
}); | ||
@@ -80,0 +80,0 @@ // Update index in results with computed values |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
281513