Skip to content

Commit

Permalink
fix(client): Restore non-namespaced PrismaPromise export
Browse files Browse the repository at this point in the history
Fix #18143
  • Loading branch information
SevInf committed Mar 24, 2023
1 parent 5c86252 commit 118fc3b
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -329,6 +329,8 @@ type UnwrapTuple<Tuple extends readonly unknown[]> = {
[K in keyof Tuple]: K extends \`\${number}\` ? Tuple[K] extends Prisma.PrismaPromise<infer X> ? X : UnwrapPromise<Tuple[K]> : UnwrapPromise<Tuple[K]>
};

export type PrismaPromise<T> = runtime.Types.Public.PrismaPromise<T>


/**
* Model Embed
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -345,6 +345,8 @@ type UnwrapTuple<Tuple extends readonly unknown[]> = {
[K in keyof Tuple]: K extends \`\${number}\` ? Tuple[K] extends Prisma.PrismaPromise<infer X> ? X : UnwrapPromise<Tuple[K]> : UnwrapPromise<Tuple[K]>
};

export type PrismaPromise<T> = runtime.Types.Public.PrismaPromise<T>


/**
* Model Post
Expand Down
2 changes: 2 additions & 0 deletions packages/client/src/generation/TSClient/common.ts
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,8 @@ type UnwrapPromise<P extends any> = P extends Promise<infer R> ? R : P
type UnwrapTuple<Tuple extends readonly unknown[]> = {
[K in keyof Tuple]: K extends \`\$\{number\}\` ? Tuple[K] extends Prisma.PrismaPromise<infer X> ? X : UnwrapPromise<Tuple[K]> : UnwrapPromise<Tuple[K]>
};
export type PrismaPromise<T> = runtime.Types.Public.PrismaPromise<T>
`,
ts: () => `export import DMMF = runtime.DMMF
Expand Down

0 comments on commit 118fc3b

Please sign in to comment.