get password from config file

This commit is contained in:
Luke Slater 2011-11-24 13:19:18 +00:00
parent 8726c87c23
commit 365ef7d5fc

4
run.js
View File

@ -11,11 +11,13 @@ var DBot = function(dModules, timers) {
this.admin = this.config.admin || 'reality'; this.admin = this.config.admin || 'reality';
this.name = this.config.name || 'depressionbot'; this.name = this.config.name || 'depressionbot';
this.password = this.config.password || 'lolturtles';
this.timers = timers.create(); this.timers = timers.create();
this.waitingForKarma = false; this.waitingForKarma = false;
this.instance = jsbot.createJSBot(this.name, 'elara.ivixor.net', 6667, this, function() { this.instance = jsbot.createJSBot(this.name, 'elara.ivixor.net', 6667, this, this.password,
function() {
if(this.config.hasOwnProperty('channels')) { if(this.config.hasOwnProperty('channels')) {
this.config.channels.each(function(channel) { this.config.channels.each(function(channel) {
this.instance.join(channel); this.instance.join(channel);