lib/middleware/content/validate.js
function validateFields(contentType, cb) {
        if (_.isArray(contentType.fields)) {
            async.each(contentType.fields, validateField, function(err) {
                cb(err);
            });
        } else {
            cb();
        }
    }
function validateFields(contentType, cb) {
        if (_.isArray(contentType.fields)) {
            async.each(contentType.fields, validateField, function(err) {
                cb(err);
            });
        } else {
            cb();
        }
    }
function validateFields ( contentType , cb ) { if ( _ . isArray ( contentType . fields ) ) { async . each ( contentType . fields , validateField , function ( err ) { cb ( err ) ; } ) ; } else { cb ( ) ; } }
Function will iterate all the fields in the content type and check the validation rules for each one.
Function will iterate all the fields in the content type and check the validation rules for each one .