mirror of
https://github.com/bower/bower.git
synced 2026-02-11 22:44:58 -05:00
Fix render of errors.
This commit is contained in:
@@ -23,7 +23,8 @@ StandardRenderer.prototype.error = function (err) {
|
||||
|
||||
err.id = err.code || 'error';
|
||||
err.level = 'error';
|
||||
str = this._prefix(err) + ' ' + err.message + '\n';
|
||||
|
||||
str = this._prefixNotification(err) + ' ' + err.message + '\n';
|
||||
|
||||
// Check if additional details were provided
|
||||
if (err.details) {
|
||||
@@ -67,10 +68,13 @@ StandardRenderer.prototype._genericNotification = function (notification) {
|
||||
var stream;
|
||||
var str;
|
||||
|
||||
notification.message = notification.message || '';
|
||||
stream = notification.level === 'warn' ? process.stderr : process.stdout;
|
||||
str = this._prefixNotification(notification) + ' ' + notification.message + '\n';
|
||||
if (notification.level === 'warn') {
|
||||
stream = process.stderr;
|
||||
} else {
|
||||
stream = process.stdout;
|
||||
}
|
||||
|
||||
str = this._prefixNotification(notification) + ' ' + notification.message + '\n';
|
||||
this._write(stream, 'bower ' + str);
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user