structured-elements
Version:
A TypeScript package for modelling and validating data
15 lines • 502 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.attemptSalvageCollection = void 0;
// eslint-disable-next-line @typescript-eslint/no-explicit-any
const attemptSalvageCollection = ({ failures, subject, validElements, }) => {
if (failures.length === 0) {
return subject;
}
if (validElements) {
return validElements;
}
return {};
};
exports.attemptSalvageCollection = attemptSalvageCollection;
//# sourceMappingURL=collection.js.map