summaryrefslogtreecommitdiff
path: root/deps/npm/node_modules/colors/lib/maps/rainbow.js
diff options
context:
space:
mode:
Diffstat (limited to 'deps/npm/node_modules/colors/lib/maps/rainbow.js')
-rw-r--r--deps/npm/node_modules/colors/lib/maps/rainbow.js13
1 files changed, 6 insertions, 7 deletions
diff --git a/deps/npm/node_modules/colors/lib/maps/rainbow.js b/deps/npm/node_modules/colors/lib/maps/rainbow.js
index 5442744369..874508da8e 100644
--- a/deps/npm/node_modules/colors/lib/maps/rainbow.js
+++ b/deps/npm/node_modules/colors/lib/maps/rainbow.js
@@ -1,12 +1,11 @@
-var colors = require('../colors');
-
-module['exports'] = (function () {
- var rainbowColors = ['red', 'yellow', 'green', 'blue', 'magenta']; //RoY G BiV
- return function (letter, i, exploded) {
- if (letter === " ") {
+module['exports'] = function(colors) {
+ // RoY G BiV
+ var rainbowColors = ['red', 'yellow', 'green', 'blue', 'magenta'];
+ return function(letter, i, exploded) {
+ if (letter === ' ') {
return letter;
} else {
return colors[rainbowColors[i++ % rainbowColors.length]](letter);
}
};
-})();
+};