Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/plugins/trpc/res/client/next.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { type CreateTRPCNext, createTRPCNext as _createTRPCNext } from '@trpc/ne
import type { DeepOverrideAtPath } from './utils';
import type { ClientType } from '../routers';

export function createTRPCReact<
export function createTRPCNext<
TRouter extends AnyRouter,
TPath extends string | undefined = undefined,
TSSRContext extends NextPageContext = NextPageContext,
Expand Down
6 changes: 1 addition & 5 deletions packages/plugins/trpc/src/helpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,6 @@ function getPrismaOperationTypes(model: string, operation: string) {
switch (operation) {
case 'findUnique':
case 'findUniqueOrThrow':
argsType = selectSubset;
resultType = getPayload;
break;

case 'findFirst':
case 'findFirstOrThrow':
argsType = selectSubset;
Expand All @@ -65,7 +61,7 @@ function getPrismaOperationTypes(model: string, operation: string) {

case 'findMany':
argsType = selectSubset;
resultType = getPayload;
resultType = `Array<${getPayload}>`;
break;

case 'create':
Expand Down