3
0
mirror of https://github.com/reality/dbot.git synced 2024-12-27 21:22:38 +01:00
dbot/modules/puns.js

20 lines
536 B
JavaScript
Raw Normal View History

var puns = function(dbot) {
var dbot = dbot;
return {
'listener': function(data) {
if(data.user == 'reality') {
2012-03-07 23:13:31 +01:00
dbot.instance.say(data.channel, dbot.interpolatedQuote('realityonce'));
} else if(dbot.db.quoteArrs.hasOwnProperty(data.user.toLowerCase())) {
2012-03-07 23:13:31 +01:00
dbot.say(data.channel, data.user + ': ' + dbot.interpolatedQuote(data.user.toLowerCase()));
}
},
'on': 'JOIN'
};
}
exports.fetch = function(dbot) {
return puns(dbot);
};