UNPKG

livr

Version:

Lightweight validator supporting Language Independent Validation Rules Specification

11 lines (9 loc) 216 B
function not_empty() { return value => { if (value !== null && value !== undefined && value === '') { return 'CANNOT_BE_EMPTY'; } return; }; } module.exports = not_empty;