You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
356 B
17 lines
356 B
exports = module.exports = require('./lib');
|
|
|
|
// if this is being run directly, then attempt to load it as
|
|
// server instead of module
|
|
if (module.id === '.') {
|
|
var fs = require('fs'),
|
|
path = require('path'),
|
|
appjs = path.join(__dirname, 'app.js');
|
|
if (fs.existsSync(appjs)) {
|
|
try {
|
|
require(appjs);
|
|
}
|
|
catch (E) {
|
|
console.error(E);
|
|
}
|
|
}
|
|
}
|