From 694e1bf8578bdfce22eb3641b1cf70c88c46498e Mon Sep 17 00:00:00 2001 From: reality Date: Tue, 9 Apr 2013 15:28:56 +0000 Subject: [PATCH 1/2] fix regex and add g and b colour codes --- modules/flashy/flashy.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/modules/flashy/flashy.js b/modules/flashy/flashy.js index 407dba0..840311d 100644 --- a/modules/flashy/flashy.js +++ b/modules/flashy/flashy.js @@ -7,7 +7,9 @@ var _ = require('underscore')._; var flashy = function(dbot) { this.colourMap = { - 'red': 'FF0000' + 'red': 'FF0000', + 'green': '00FF00', + 'blue': '0000FF' }; this.commands = { @@ -27,7 +29,7 @@ var flashy = function(dbot) { } }; - this.commands['~flashy'].regex = [/^~qadd ([\d\w-]+[\d\w\s-]*)[ ]?=[ ]?(.+)$/, 3]; + this.commands['~flashy'].regex = [/^~flashy ([\d\w-]+[\d\w\s-]*)[ ]?=[ ]?(.+)$/, 3]; }; exports.fetch = function(dbot) { From 4d5fa0427799780ca0971a62a74af7088fc683d2 Mon Sep 17 00:00:00 2001 From: reality Date: Tue, 9 Apr 2013 15:30:56 +0000 Subject: [PATCH 2/2] fix render to point to text proeprly --- modules/flashy/pages.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/flashy/pages.js b/modules/flashy/pages.js index 5b09dd8..6b46ba5 100644 --- a/modules/flashy/pages.js +++ b/modules/flashy/pages.js @@ -10,7 +10,7 @@ var pages = function(dbot) { res.render('flashy', { 'name': dbot.config.name, 'colour': colour, - 'text': text + 'text': req.params.text }); } };