lib/routesHandler/lib/preconditionsCheck.js
function (values, model, type) {
        var deferred = Q.defer();
        var modelData = {data: model};

        ModelValidator.validate(values, modelData, function (err, data) {
            deferred.resolve({data: data, err: err, type: type});
        });
        return deferred.promise;
    }
function (values, model, type) {
        var deferred = Q.defer();
        var modelData = {data: model};

        ModelValidator.validate(values, modelData, function (err, data) {
            deferred.resolve({data: data, err: err, type: type});
        });
        return deferred.promise;
    }
function ( values , model , type ) { var deferred = Q . defer ( ) ; var modelData = { data : model } ; ModelValidator . validate ( values , modelData , function ( err , data ) { deferred . resolve ( { data : data , err : err , type : type } ) ; } ) ; return deferred . promise ; }
Validate given values using given model
@param values
@param model
@param type
@returns {*}
@private
Validate given values using given model