From 5e1b2489363c2ce7de737e25659f8e7e9bc7755c Mon Sep 17 00:00:00 2001 From: Stephan Brandauer Date: Wed, 24 May 2023 14:14:46 +0000 Subject: [PATCH] for testing; don't merge this --- src/util.ts | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) diff --git a/src/util.ts b/src/util.ts index b8c4a751f..925b22ef7 100644 --- a/src/util.ts +++ b/src/util.ts @@ -891,17 +891,12 @@ export function fixInvalidNotificationsInFile( outputPath: string, logger: Logger ): void { - if (process.env[CODEQL_ACTION_DISABLE_DUPLICATE_LOCATION_FIX] === "true") { - logger.info( - "SARIF notification object duplicate location fix disabled by the " + - `${CODEQL_ACTION_DISABLE_DUPLICATE_LOCATION_FIX} environment variable.` - ); - fs.renameSync(inputPath, outputPath); - } else { - let sarif = JSON.parse(fs.readFileSync(inputPath, "utf8")) as SarifFile; - sarif = fixInvalidNotifications(sarif, logger); - fs.writeFileSync(outputPath, JSON.stringify(sarif)); - } + // XXX never merge this + logger.info( + "SARIF notification object duplicate location fix disabled by the " + + `${CODEQL_ACTION_DISABLE_DUPLICATE_LOCATION_FIX} environment variable.` + ); + fs.renameSync(inputPath, outputPath); } export function wrapError(error: unknown): Error {