Skip to content

Commit

Permalink
show correct version when it's inherited from parent (#851)
Browse files Browse the repository at this point in the history
Signed-off-by: Yan Zhang <[email protected]>
  • Loading branch information
Eskibear authored Jul 25, 2022
1 parent 6594626 commit 2d07a1c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/explorer/model/MavenProject.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export class MavenProject implements ITreeItem {
}

public get version(): string {
return this._pom?.project?.version?.[0];
return this._pom?.project?.version?.[0] ?? this._pom?.project?.parent?.[0]?.version?.[0] ?? this.parent?.version;
}

public get id(): string {
Expand Down

0 comments on commit 2d07a1c

Please sign in to comment.