add rebuilt lib

This commit is contained in:
Stephan Brandauer 2023-05-24 12:12:27 +00:00
parent 153cab09da
commit 636b9eab1d
2 changed files with 11 additions and 1 deletions

10
lib/util.js generated
View file

@ -722,6 +722,16 @@ function fixInvalidNotifications(sarif, logger) {
return newSarif;
}
exports.fixInvalidNotifications = fixInvalidNotifications;
/**
* Removes duplicates from the sarif file.
*
* When `CODEQL_ACTION_DISABLE_DUPLICATE_LOCATION_FIX` is set to true, this will
* simply rename the input file to the output file. Otherwise, it will parse the
* input file as JSON, remove duplicate locations from the SARIF notification
* objects, and write the result to the output file.
*
* For context, see documentation of:
* `CODEQL_ACTION_DISABLE_DUPLICATE_LOCATION_FIX`. */
function fixInvalidNotificationsInFile(inputPath, outputPath, logger) {
if (process.env[shared_environment_1.CODEQL_ACTION_DISABLE_DUPLICATE_LOCATION_FIX] === "true") {
logger.info("SARIF notification object duplicate location fix disabled by the " +

File diff suppressed because one or more lines are too long