Return empty string if Helm release version is not detected (#342)

Signed-off-by: Lauri Nevala <lauri.nevala@gmail.com>
This commit is contained in:
Lauri Nevala authored and GitHub committed 2020-05-05 07:28:54 +03:00
1 parent 8d2e8bbe62
commit dd8dc23514
1 file changed
+6 -1
@@ -170,7 +170,12 @@ export class HelmRelease implements ItemObject {
}
getVersion() {
return this.chart.match(/(\d+)[^-]*$/)[0];
const versions = this.chart.match(/(\d+)[^-]*$/)
if (versions) {
return versions[0]
} else {
return ""
}
}
getUpdated(humanize = true, compact = true) {