Skip to content

Commit

Permalink
Merge pull request #1048 from nscuro/issue-1026
Browse files Browse the repository at this point in the history
Always display project nodes in dependency graph using name and version
  • Loading branch information
nscuro authored Oct 9, 2024
2 parents 1ef67d3 + 856ff46 commit 4fdb56e
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/views/portfolio/projects/ProjectDependencyGraph.vue
Original file line number Diff line number Diff line change
Expand Up @@ -529,10 +529,12 @@ export default {
}
},
createNodeLabel: function (identity) {
// could be a project or a component
if (identity.purlCoordinates) {
// Could be a project or a directDependency object.
// Projects don't have the objectType property.
const isProject = !identity.objectType;
if (!isProject && identity.purlCoordinates) {
return identity.purlCoordinates;
} else if (identity.purl) {
} else if (!isProject && identity.purl) {
return identity.purl;
} else {
let label = '';
Expand Down

0 comments on commit 4fdb56e

Please sign in to comment.