Skip to content

Commit

Permalink
Dont yaml.load unless there an apiVersion in the output
Browse files Browse the repository at this point in the history
  • Loading branch information
Stono committed Feb 6, 2021
1 parent c5c4c1b commit 8bac554
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions lib/helm.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,9 @@ const HelmResultParser = function() {
}
let json;
try {
if (!manifest.includes('apiVersion')) {
return nextManifest();
}
json = YAML.load(manifest);
} catch(ex) {
const err = new Error('Failed to parse manifest: ' + source);
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "helm-test",
"description": "A CLI to test Helm charts",
"version": "0.5.0",
"version": "0.5.1",
"homepage": "https://github.com/Stono/helm-test",
"author": {
"name": "Karl Stoney",
Expand Down

0 comments on commit 8bac554

Please sign in to comment.