diff --git a/packages/generator/src/compiler.ts b/packages/generator/src/compiler.ts index ec3d849..9ca8708 100644 --- a/packages/generator/src/compiler.ts +++ b/packages/generator/src/compiler.ts @@ -827,7 +827,7 @@ export class PrismaAppSyncCompiler { // Return relation kind (`one` or `many`) from Prisma type private getFieldRelationKind(field: DMMF.Field): 'one' | 'many' { - return field.relationFromFields && field.relationFromFields.length === 1 ? 'one' : 'many' + return !field.isList ? 'one' : 'many' } // Get AppSync scalar from Prisma type