diff --git a/packages/@aws-cdk/aws-eks/lib/cluster-resource-handler/common.ts b/packages/@aws-cdk/aws-eks/lib/cluster-resource-handler/common.ts index 6f17be9738019..57d3ae20f8cef 100644 --- a/packages/@aws-cdk/aws-eks/lib/cluster-resource-handler/common.ts +++ b/packages/@aws-cdk/aws-eks/lib/cluster-resource-handler/common.ts @@ -14,22 +14,6 @@ export interface EksUpdateId { export type ResourceEvent = AWSLambda.CloudFormationCustomResourceEvent & EksUpdateId; -/** - * Decodes encoded true/false values - */ -function decodeBooleans(object: object) { - return JSON.parse(JSON.stringify(object), (_k, v) => { - switch (v) { - case 'TRUE:BOOLEAN': - return true; - case 'FALSE:BOOLEAN': - return false; - default: - return v; - } - }); -} - export abstract class ResourceHandler { protected readonly requestId: string; protected readonly logicalResourceId: string; @@ -49,10 +33,6 @@ export abstract class ResourceHandler { throw new Error('AssumeRoleArn must be provided'); } - if (event.ResourceProperties.Config) { - this.event.ResourceProperties.Config = decodeBooleans(event.ResourceProperties.Config); - } - eks.configureAssumeRole({ RoleArn: roleToAssume, RoleSessionName: `AWSCDK.EKSCluster.${this.requestType}.${this.requestId}`,