Skip to content

Commit

Permalink
fix: stringify error
Browse files Browse the repository at this point in the history
  • Loading branch information
develar committed Jan 13, 2018
1 parent 37d6977 commit a6d2796
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions packages/builder-util/src/log.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,10 @@ export class Logger {
}

private doLog(message: string | undefined, messageOrFields: Fields | null | string, level: LogLevel) {
if (message instanceof Error) {
message = message.stack
}

if (message === undefined) {
this._doLog(messageOrFields as string, null, level)
}
Expand Down

0 comments on commit a6d2796

Please sign in to comment.