The data helper is missing an undefined check. If I call data("some.invalid.key.path"), then I get TypeError: Cannot read property 'contents' of undefined. From the stacktrace, I see it's a problem with data, but have no idea about what input is causing the problem.
More useful might be to throw an error that indicates that the data is missing at the given path. If that strictness isn't needed/intended, I could imagine instead logging a warning and continuing, but I don't see any patterns like that used elsewhere in the builder.
The data helper is missing an undefined check. If I call
data("some.invalid.key.path")
, then I getTypeError: Cannot read property 'contents' of undefined
. From the stacktrace, I see it's a problem with data, but have no idea about what input is causing the problem.More useful might be to throw an error that indicates that the data is missing at the given path. If that strictness isn't needed/intended, I could imagine instead logging a warning and continuing, but I don't see any patterns like that used elsewhere in the builder.