glee protection

This commit is contained in:
Luke Slater 2011-11-10 13:17:44 +00:00
parent 9e3bbb31c9
commit 47ddeb8b50
2 changed files with 2 additions and 2 deletions

View File

@ -10,7 +10,7 @@ var quotes = function(dbot) {
key = q[1].trim().toLowerCase();
if(quotes.hasOwnProperty(key)) {
var output = quotes[key].random();
if(output == "glee") {
if(output.indexOf("glee") != -1) {
dbot.instance.send('KICK ' + data.channel + ' ' + data.user + ' :glee off dickhead');
} else {
dbot.say(data.channel, key + ': ' + output);

2
run.js
View File

@ -103,7 +103,7 @@ DBot.prototype.reloadModules = function() {
key = q[1].trim().toLowerCase();
if(this.db.quoteArrs.hasOwnProperty(key)) {
var output = this.db.quoteArrs[key].random();
if(output == "glee") {
if(output.indexOf("glee") != -1) {
dbot.instance.send('KICK ' + data.channel + ' ' + data.user + ' :glee off dickhead');
} else {
this.say(data.channel, key + ': ' + output);