packages/lambda/src/index.js
function findLambda(identifier) {
  return loadLambdas()
  .then(lambdas => {
    const lambda = _.find(lambdas, (lambda) => { return lambda.getIdentifier() === identifier; });
    if (!lambda) {
      throw new Error('The Lambda "' + identifier + '" does not exists in this Myrmex project');
    }
    return lambda;
  });
}
function findLambda(identifier) {
  return loadLambdas()
  .then(lambdas => {
    const lambda = _.find(lambdas, (lambda) => { return lambda.getIdentifier() === identifier; });
    if (!lambda) {
      throw new Error('The Lambda "' + identifier + '" does not exists in this Myrmex project');
    }
    return lambda;
  });
}
function findLambda ( identifier ) { return loadLambdas ( ) . then ( lambdas => { const lambda = _ . find ( lambdas , ( lambda ) => { return lambda . getIdentifier ( ) === identifier ; } ) ; if ( ! lambda ) { throw new Error ( 'The Lambda "' + identifier + '" does not exists in this Myrmex project' ) ; } return lambda ; } ) ; }
Find an Lambda by its identifier
@param {string} name - the name of the Lambda
@returns {Array}
Find an Lambda by its identifier