Skip to content

Commit

Permalink
fix: do not throw error when parent of nested field is missing
Browse files Browse the repository at this point in the history
Instead of erroring when the parent of a nexted field is missing, just
return the empty value.
  • Loading branch information
adrianschmidt committed Mar 7, 2024
1 parent 4ff8693 commit 7732cfc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ try {
var parsed = toml.parse(str);
var value = parsed;
fields.forEach(function (f) {
value = value[f];
value = value?.[f];
});
core.setOutput("value", value);
} catch (error) {
Expand Down

0 comments on commit 7732cfc

Please sign in to comment.