diff --git a/modules/web/web.js b/modules/web/web.js index 267ebb0..b7e47b4 100644 --- a/modules/web/web.js +++ b/modules/web/web.js @@ -82,7 +82,7 @@ var webInterface = function(dbot) { _.extend(one, { 'name': dbot.config.name, 'user': req.user, - 'modules': this.indexLinks + 'routes': this.indexLinks }); resp.render(this.module + '/' + view, one, two); }).bind(this); @@ -106,6 +106,8 @@ var webInterface = function(dbot) { } }.bind(this)); + this.reloadPages(); + this.app.get('/', function(req, res) { res.render('index', { 'name': dbot.config.name, diff --git a/run.js b/run.js index 5367d5d..f1a1683 100644 --- a/run.js +++ b/run.js @@ -306,7 +306,6 @@ DBot.prototype.reloadModules = function() { }.bind(this)); process.nextTick(function() { - if(_.has(this.modules, 'web')) this.modules.web.reloadPages(); _.each(this.modules, function(module, name) { if(module.onLoad) { try {