From 285dfe10a5c06d4a86176b54bef2d7591eedaf40 Mon Sep 17 00:00:00 2001 From: Nathan Rajlich Date: Thu, 9 Nov 2017 12:35:02 -0800 Subject: [PATCH] fix colors with `supports-color@5` --- src/node.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/node.js b/src/node.js index b32d831a..c13b932c 100644 --- a/src/node.js +++ b/src/node.js @@ -24,7 +24,7 @@ exports.colors = [ 6, 2, 3, 4, 5, 1 ]; try { var supportsColor = require('supports-color'); - if (supportsColor && supportsColor.level >= 2) { + if (supportsColor && (supportsColor.stderr || supportsColor).level >= 2) { exports.colors = [ 20, 21, 26, 27, 32, 33, 38, 39, 40, 41, 42, 43, 44, 45, 56, 57, 62, 63, 68, 69, 74, 75, 76, 77, 78, 79, 80, 81, 92, 93, 98, 99, 112, 113, 128, 129, 134,