Skip to content

Commit

Permalink
Fix summary artifact not generating on first load
Browse files Browse the repository at this point in the history
  • Loading branch information
rhyskoedijk committed Jan 3, 2025
1 parent b1b3584 commit 6057251
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions ui/sbom-report-tab.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -172,9 +172,6 @@ export class Root extends React.Component<{}, State> {
}
}

// Generate a summary SBOM artifact if multiple artifacts were loaded
this.generateSbomSummaryArtifact();

// Update the state with the loaded SBOM artifacts
console.info(`Loaded ${Object.keys(sbomArtifacts).length} SBOM artifact(s) for build ${buildId}`);
this.selectedArtifactId.value = sbomArtifacts[0]?.spdxDocument?.documentNamespace || '';
Expand All @@ -183,6 +180,9 @@ export class Root extends React.Component<{}, State> {
loadingMessage: undefined,
loadError: undefined,
});

// Generate a summary SBOM artifact if multiple artifacts were loaded
this.generateSbomSummaryArtifact();
} catch (error) {
console.error(error);
this.setState({ loadError: error });
Expand Down

0 comments on commit 6057251

Please sign in to comment.