Skip to content

Commit 412bbfb

Browse files
committed
feat: Allow TransactionError to be caused by Deno.errors.BrokenPipe
1 parent 014f600 commit 412bbfb

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

client/error.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ export class TransactionError extends Error {
5858
/**
5959
* Create a transaction error with a message and a cause
6060
*/
61-
constructor(transaction_name: string, cause: PostgresError) {
61+
constructor(transaction_name: string, cause: PostgresError | Deno.errors.BrokenPipe) {
6262
super(`The transaction "${transaction_name}" has been aborted`, { cause });
6363
this.name = "TransactionError";
6464
}

0 commit comments

Comments
 (0)