Skip to content

Commit 36a53f6

Browse files
maxcbcporsager
authored andcommitted
omit Sql properties absent from TransactionSql
1 parent 3ffc3c4 commit 36a53f6

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

types/index.d.ts

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -715,7 +715,20 @@ declare namespace postgres {
715715
prepare?: boolean | undefined;
716716
}
717717

718-
interface TransactionSql<TTypes extends Record<string, unknown> = {}> extends Sql<TTypes> {
718+
interface TransactionSql<TTypes extends Record<string, unknown> = {}> extends Omit<Sql<TTypes>,
719+
'parameters' |
720+
'largeObject' |
721+
'subscribe' |
722+
'CLOSE' |
723+
'END' |
724+
'PostgresError' |
725+
'options' |
726+
'reserve' |
727+
'listen' |
728+
'begin' |
729+
'close' |
730+
'end'
731+
> {
719732
savepoint<T>(cb: (sql: TransactionSql<TTypes>) => T | Promise<T>): Promise<UnwrapPromiseArray<T>>;
720733
savepoint<T>(name: string, cb: (sql: TransactionSql<TTypes>) => T | Promise<T>): Promise<UnwrapPromiseArray<T>>;
721734

0 commit comments

Comments
 (0)