face-api/build/factories/WithAge.js

8 lines
246 B
JavaScript
Raw Normal View History

2020-08-20 02:10:42 +02:00
export function isWithAge(obj) {
2020-08-18 14:04:33 +02:00
return typeof obj['age'] === 'number';
}
2020-08-20 02:10:42 +02:00
export function extendWithAge(sourceObj, age) {
2020-08-18 14:04:33 +02:00
const extension = { age };
return Object.assign({}, sourceObj, extension);
}
//# sourceMappingURL=WithAge.js.map