heroku-cli-util
Advanced tools
Comparing version 5.6.1 to 5.6.2
@@ -8,2 +8,8 @@ 'use strict'; | ||
function apiMiddleware (response, cb) { | ||
let warning = response.headers['warning-message']; | ||
if (warning) cli.warn(warning); | ||
cb(); | ||
} | ||
function heroku (context) { | ||
@@ -18,3 +24,4 @@ let host = context.apiUrl || 'https://api.heroku.com'; | ||
headers: {}, | ||
rejectUnauthorized: !(process.env.HEROKU_SSL_VERIFY === 'disable' || host.endsWith('herokudev.com')) | ||
rejectUnauthorized: !(process.env.HEROKU_SSL_VERIFY === 'disable' || host.endsWith('herokudev.com')), | ||
middleware: apiMiddleware, | ||
}; | ||
@@ -21,0 +28,0 @@ if (process.env.HEROKU_HEADERS) { |
@@ -53,3 +53,3 @@ 'use strict'; | ||
function warn (msg) { | ||
console.error(bangify(wrap(msg), cli.color.yellow(arrow))); | ||
console.error(bangify(wrap(`WARNING: ${msg}`), cli.color.yellow(arrow))); | ||
} | ||
@@ -56,0 +56,0 @@ |
{ | ||
"name": "heroku-cli-util", | ||
"version": "5.6.1", | ||
"version": "5.6.2", | ||
"description": "Set of helpful CLI utilities", | ||
@@ -22,3 +22,3 @@ "main": "index.js", | ||
"mocha": "^2.2.4", | ||
"nock": "^2.6.0" | ||
"nock": "3.1.1" | ||
}, | ||
@@ -28,5 +28,5 @@ "dependencies": { | ||
"co": "4.6.0", | ||
"heroku-client": "2.3.2", | ||
"heroku-client": "2.4.0", | ||
"lodash": "3.10.1" | ||
} | ||
} |
@@ -6,5 +6,7 @@ 'use strict'; | ||
describe('errors', function () { | ||
beforeEach(() => cli.mockConsole()); | ||
it('prints out errors', function () { | ||
cli.error('foobar'); | ||
expect(cli.color.stripColor(cli.stderr)).to.contain(' ▸ foobar\n'); | ||
expect(cli.color.stripColor(cli.stderr)).to.equal(' ▸ foobar\n'); | ||
}); | ||
@@ -14,4 +16,4 @@ | ||
cli.warn('foobar'); | ||
expect(cli.color.stripColor(cli.stderr)).to.contain(' ▸ foobar\n'); | ||
expect(cli.color.stripColor(cli.stderr)).to.equal(' ▸ WARNING: foobar\n'); | ||
}); | ||
}); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
71254
1723
+ Addedheroku-client@2.4.0(transitive)
- Removedheroku-client@2.3.2(transitive)
Updatedheroku-client@2.4.0