function loadTemplates(list, type) {
  if (!list) {
    return;
  }

  var result = {};

  type = type || 'plaintext';

  list.forEach(function (name) {
    var templatePath = path.join(templateBasePath, type, `${name}.pug`);
    result[name] = renderPug(templatePath);
  });

  return result;
}
/*
 * loading all of the email templates at server start
 */
loading all of the email templates at server start
loading all of the email templates at server start
function loadTemplates(list, type) {
  if (!list) {
    return;
  }
  var result = {};
  type = type || 'plaintext';
  list.forEach(function (name) {
    var templatePath = path.join(templateBasePath, type, `${name}.pug`);
    result[name] = renderPug(templatePath);
  });
  return result;
}
function loadTemplates ( list , type ) { if ( ! list ) { return ; } var result = { } ; type = type || 'plaintext' ; list . forEach ( function ( name ) { var templatePath = path . join ( templateBasePath , type , ` ${ name } ` ) ; result [ name ] = renderPug ( templatePath ) ; } ) ; return result ; }
loading all of the email templates at server start
loading all of the email templates at server start