now handles exceptions that aren't Errors
This commit is contained in:
@@ -279,9 +279,13 @@ module.exports = function (fileSystem, standardOutput, configPaths) {
|
||||
this.startTime = new Date();
|
||||
this.categoryName = categoryName;
|
||||
this.message = message;
|
||||
this.exception = exception;
|
||||
this.level = level;
|
||||
this.logger = logger;
|
||||
if (exception && exception.message && exception.name) {
|
||||
this.exception = exception;
|
||||
} else if (exception) {
|
||||
this.exception = new Error(exception);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user