var transformer = require('transformer');

/**
 * @param {Object} object
 * @param {Object} config
 *
 * @returns {Promise}
 */
module.exports = function(object, config) {
    return transformer(object, config)
        .setDefaults()
        .filter()
        .validate({ maxPropertyErrorsCount: 1 })
        .clean()
        .result
};
var transformer = require('transformer');

/**
 * @param {Object} object
 * @param {Object} config
 *
 * @returns {Promise}
 */
module.exports = function(object, config) {
    return transformer(object, config)
        .setDefaults()
        .filter()
        .validate({ maxPropertyErrorsCount: 1 })
        .clean()
        .result;
};

Update transformRequest.js