Skip to content

Commit

Permalink
Update supports-colors.js
Browse files Browse the repository at this point in the history
  • Loading branch information
paladox committed Feb 14, 2018
1 parent 34a3d33 commit 2dc605c
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions lib/system/supports-colors.js
Expand Up @@ -24,10 +24,10 @@ THE SOFTWARE.
*/

'use strict';
const os = require('os');
const hasFlag = require('./has-flag.js');
var os = require('os');
var hasFlag = require('./has-flag.js');

const env = process.env;
var env = process.env;

let forceColor;
if (hasFlag('no-color') ||
Expand Down Expand Up @@ -85,7 +85,7 @@ function supportsColor(stream) {
// release, and Node.js 7 is not. Windows 10 build 10586 is the first Windows
// release that supports 256 colors. Windows 10 build 14931 is the first release
// that supports 16m/TrueColor.
const osRelease = os.release().split('.');
var osRelease = os.release().split('.');
if (
Number(process.versions.node.split('.')[0]) >= 8 &&
Number(osRelease[0]) >= 10 &&
Expand All @@ -110,7 +110,7 @@ function supportsColor(stream) {
}

if ('TERM_PROGRAM' in env) {
const version = parseInt((env.TERM_PROGRAM_VERSION || '').split('.')[0], 10);
var version = parseInt((env.TERM_PROGRAM_VERSION || '').split('.')[0], 10);

switch (env.TERM_PROGRAM) {
case 'iTerm.app':
Expand Down

0 comments on commit 2dc605c

Please sign in to comment.