diff --git a/modules/quotes.js b/modules/quotes.js index d33e91b..9bf337d 100644 --- a/modules/quotes.js +++ b/modules/quotes.js @@ -108,6 +108,10 @@ var quotes = function(dbot) { addStack.push(q[1]); rmAllowed = true; dbot.say(data.channel, 'Quote saved in \'' + q[1] + '\' (' + quotes[key].length + ')'); + + if(data.channel == 'reality') { + dbot.say('#realitest', 'Public Service Announcement: Snow added \'' + q[1] + '\' to ' + key + ' in PM'); + } } else { dbot.say(data.channel, 'Invalid syntax. Initiate incineration.'); } diff --git a/modules/spelling.js b/modules/spelling.js index 40a33db..2e98a02 100644 --- a/modules/spelling.js +++ b/modules/spelling.js @@ -4,8 +4,8 @@ var spelling = function(dbot) { return { 'listener': function(data, params) { - var q = data.message.valMatch(/^\*\*?([\d\w\s]*)$/, 2); - var otherQ = data.message.valMatch(/^([\d\w\s]*): \*\*?([\d\w\s]*)$/, 3); + var q = data.message.valMatch(/^\([\d\w\s]*: )?*\*?([\d\w\s]*)$/, 2); + var otherQ = data.message.valMatch(/^ \*\*?([\d\w\s]*)$/, 3); if(q) { var correction = q[1]; var candidates = last[data.channel][data.user].split(' ');