Skip to content

Commit

Permalink
fix(client): improve error formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
timsuchanek committed May 19, 2020
1 parent a296c2a commit de5dc8e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/packages/client/src/runtime/getPrismaClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -645,7 +645,7 @@ export class PrismaClientFetcher {
originalMethod: clientMethod,
onUs: e.isPanic,
})
message = stack + e.message
message = stack + '\n ' + e.message
}

message = this.sanitizeMessage(message)
Expand Down
2 changes: 1 addition & 1 deletion src/packages/client/src/runtime/utils/printStack.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ function renderN(n: number, max: number): string {
return String(n)
}

return String(' '.repeat(wantedLetters - hasLetters) + n)
return ' '.repeat(wantedLetters - hasLetters) + n
}

export interface ErrorArgs {
Expand Down

0 comments on commit de5dc8e

Please sign in to comment.