From 365ef7d5fc0da12ff0475e464c2f195c7b0d941f Mon Sep 17 00:00:00 2001 From: Luke Slater Date: Thu, 24 Nov 2011 13:19:18 +0000 Subject: [PATCH] get password from config file --- run.js | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/run.js b/run.js index 20b92de..c8b243d 100644 --- a/run.js +++ b/run.js @@ -11,15 +11,17 @@ var DBot = function(dModules, timers) { this.admin = this.config.admin || 'reality'; this.name = this.config.name || 'depressionbot'; + this.password = this.config.password || 'lolturtles'; this.timers = timers.create(); this.waitingForKarma = false; - this.instance = jsbot.createJSBot(this.name, 'elara.ivixor.net', 6667, this, function() { - if(this.config.hasOwnProperty('channels')) { - this.config.channels.each(function(channel) { - this.instance.join(channel); - }.bind(this)); + this.instance = jsbot.createJSBot(this.name, 'elara.ivixor.net', 6667, this, this.password, + function() { + if(this.config.hasOwnProperty('channels')) { + this.config.channels.each(function(channel) { + this.instance.join(channel); + }.bind(this)); } }.bind(this));