From 0088d88af6e3b6a38cd53a3bfb6ec7ee0c52108f Mon Sep 17 00:00:00 2001 From: reality Date: Tue, 22 Oct 2013 08:46:22 +0000 Subject: [PATCH] ensure existence of hosts and tempBans --- modules/kick/kick.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/modules/kick/kick.js b/modules/kick/kick.js index 97e1f5c..caea0f3 100644 --- a/modules/kick/kick.js +++ b/modules/kick/kick.js @@ -1,6 +1,8 @@ var _ = require('underscore')._; var kick = function(dbot) { + if(!_.has(dbot.db, 'hosts')) dbot.db.hosts = {}; + if(!_.has(dbot.db, 'tempBans')) dbot.db.tempBans = {}; this.hosts = dbot.db.hosts; this.tempBans = dbot.db.tempBans;