From 9d8835eccceef1f650825772a73f8b134df4d926 Mon Sep 17 00:00:00 2001 From: Bryan Pan Date: Tue, 30 Nov 2021 15:49:10 -0800 Subject: [PATCH] fix(appsync): remove 'id' suffix to union definition key Removing an unnecessary suffix from union definitions. --- packages/@aws-cdk/aws-appsync/lib/schema-intermediate.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/@aws-cdk/aws-appsync/lib/schema-intermediate.ts b/packages/@aws-cdk/aws-appsync/lib/schema-intermediate.ts index 6236a00ce1803..a661d4e4baf61 100644 --- a/packages/@aws-cdk/aws-appsync/lib/schema-intermediate.ts +++ b/packages/@aws-cdk/aws-appsync/lib/schema-intermediate.ts @@ -381,7 +381,7 @@ export class UnionType implements IIntermediateType { if (options.field && !(options.field.intermediateType instanceof ObjectType)) { throw new Error('Fields for Union Types must be Object Types.'); } - this.definition[options.field?.toString() + 'id'] = options.field; + this.definition[options.field.toString()] = options.field; } /**