Prevent the automationDetails to be regenerated if it already exists
This commit is contained in:
parent
47755f0910
commit
de611b2de3
3 changed files with 11 additions and 7 deletions
8
lib/upload-lib.js
generated
8
lib/upload-lib.js
generated
|
|
@ -61,9 +61,11 @@ function populateRunAutomationDetails(sarifContents, analysis_key, environment)
|
|||
}
|
||||
const sarif = JSON.parse(sarifContents);
|
||||
for (const run of sarif.runs || []) {
|
||||
run.automationDetails = {
|
||||
id: automationID,
|
||||
};
|
||||
if (run.automationDetails === undefined) {
|
||||
run.automationDetails = {
|
||||
id: automationID,
|
||||
};
|
||||
}
|
||||
}
|
||||
return JSON.stringify(sarif);
|
||||
}
|
||||
|
|
|
|||
File diff suppressed because one or more lines are too long
|
|
@ -63,9 +63,11 @@ export function populateRunAutomationDetails(
|
|||
|
||||
const sarif = JSON.parse(sarifContents);
|
||||
for (const run of sarif.runs || []) {
|
||||
run.automationDetails = {
|
||||
id: automationID,
|
||||
};
|
||||
if (run.automationDetails === undefined) {
|
||||
run.automationDetails = {
|
||||
id: automationID,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
return JSON.stringify(sarif);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue