Skip to content

Commit 41bb427

Browse files
chariskrobertbrignull
authored andcommitted
Only upload results if there are any
1 parent 057eb89 commit 41bb427

2 files changed

Lines changed: 17 additions & 12 deletions

File tree

dist/query.js

Lines changed: 8 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/query.ts

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -87,12 +87,15 @@ async function run(): Promise<void> {
8787
console.log("Running query");
8888
const runQueryResult = await runQuery(codeql, dbZip, repo.nwo, queryPack);
8989

90-
await uploadRepoResult(
91-
controllerRepoId,
92-
variantAnalysisId,
93-
repo,
94-
runQueryResult,
95-
);
90+
if (runQueryResult.resultCount > 0) {
91+
await uploadRepoResult(
92+
controllerRepoId,
93+
variantAnalysisId,
94+
repo,
95+
runQueryResult,
96+
);
97+
}
98+
9699
await setVariantAnalysisRepoSucceeded(
97100
controllerRepoId,
98101
variantAnalysisId,

0 commit comments

Comments
 (0)