
/**
 * Module dependencies.
 */

var express = require('express');
var http = require('http');
var mongoose = require('mongoose');
var app = require("./app");
var config = app.config;

var server = http.createServer(app);
var io = require("./lib/socket")(server);
var fs = require("fs");
mongoose.connect(config.mongodburi);

/** 
 * Load all modules enabled in config.modules
 * The module must have an index.js present 
 */
var modules = config.modules;
modules.forEach(function(module) {
	app.use(require("./modules/" + module));
});

server.listen(app.get('port'), function(){
  console.log('Express server listening on port ' + app.get('port'));
});


var express = require('express');
var http = require('http');
var mongoose = require('mongoose');
var app = require("./app");
var config = app.config;

var server = http.createServer(app);
var io = require("./lib/socket")(server);
var fs = require("fs");
mongoose.connect(config.mongodburi);

/** 
 * Load all modules enabled in config.modules
 * The module must have an index.js present 
 */
var modules = config.modules;
modules.forEach(function(module) {
	app.use(require("./modules/" + module));
});

server.listen(app.get('port'), function(){
  console.log('Express server listening on port ' + app.get('port'));
});


Remove old comment