lib/application.js
function loadAPI() {
  var apiPath = this.fullPath(this.paths.api);
  if (fs.existsSync(apiPath) && fs.statSync(apiPath).isDirectory()) {
    var files = protos.util.ls(apiPath, this.regex.jsFile);
    files.forEach(function(file) {
      var methods = protos.require(apiPath + "/" + file, true); // Don't use module cache (allow reloading)
      _.extend(this.api, methods);
    }, this);
  }
  this.emit('api_loaded', this.api);
}
function loadAPI() {
  var apiPath = this.fullPath(this.paths.api);
  if (fs.existsSync(apiPath) && fs.statSync(apiPath).isDirectory()) {
    var files = protos.util.ls(apiPath, this.regex.jsFile);
    files.forEach(function(file) {
      var methods = protos.require(apiPath + "/" + file, true); // Don't use module cache (allow reloading)
      _.extend(this.api, methods);
    }, this);
  }
  this.emit('api_loaded', this.api);
}
function loadAPI ( ) { var apiPath = this . fullPath ( this . paths . api ) ; if ( fs . existsSync ( apiPath ) && fs . statSync ( apiPath ) . isDirectory ( ) ) { var files = protos . util . ls ( apiPath , this . regex . jsFile ) ; files . forEach ( function ( file ) { var methods = protos . require ( apiPath + "/" + file , true ) ; // Don't use module cache (allow reloading) _ . extend ( this . api , methods ) ; } , this ) ; } this . emit ( 'api_loaded' , this . api ) ; }
Loads the Application API
Loads the Application API