lib/cf-resources/lambda-version-resource/index.js
function functionPublishVersion(name, description, hash) {
    return new Promise((resolve, reject) => {
        lambda.publishVersion({
            FunctionName: name,
            Description: description,
            CodeSha256: hash
        }, function(err, data) {
            if (err) return reject(err);
            resolve(data);
        });
    });
}
function functionPublishVersion(name, description, hash) {
    return new Promise((resolve, reject) => {
        lambda.publishVersion({
            FunctionName: name,
            Description: description,
            CodeSha256: hash
        }, function(err, data) {
            if (err) return reject(err);
            resolve(data);
        });
    });
}
function functionPublishVersion ( name , description , hash ) { return new Promise ( ( resolve , reject ) => { lambda . publishVersion ( { FunctionName : name , Description : description , CodeSha256 : hash } , function ( err , data ) { if ( err ) return reject ( err ) ; resolve ( data ) ; } ) ; } ) ; }
Publish a new Lambda function version

@return {Promise} which resolves into the newly published version
Publish a new Lambda function version