3
0
mirror of https://github.com/reality/dbot.git synced 2024-11-24 04:49:25 +01:00

fix regex examples

This commit is contained in:
reality 2015-03-24 19:26:41 +00:00
parent 33c50671e6
commit ac2f7bbccd

View File

@ -114,6 +114,7 @@ var words = function(dbot) {
this.listener = function(event) { this.listener = function(event) {
var matchOne = event.message.match(new RegExp(dbot.config.name + var matchOne = event.message.match(new RegExp(dbot.config.name +
': should (\\w+) (.+) or (.*)\\?', 'i')); ': should (\\w+) (.+) or (.*)\\?', 'i'));
event.reply(matchOne);
if(matchOne) { if(matchOne) {
var pre = match[1]; var pre = match[1];
if(pre == 'i' || pre == 'I') { if(pre == 'i' || pre == 'I') {