Skip to content

(aws-cloudfront): Invalid GeoRestriction Docs #19022

@HariboDev

Description

@HariboDev

link to reference doc page

https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_cloudfront.GeoRestriction.html#class-georestriction

Describe your issue?

In the docs, the example refers to cloudfront.GeoRestriction.whitelist(), however this method is deprecated in the CDK v2 and should be updated to cloudfront.GeoRestriction.allowlist().

Additionally, the string[] in the example uses US and UK but UK is not officially assigned in the ISO 3166-1-alpha-2 standard and if used, causes an error. This should be updated to be GB.

Reference
ISO 3166-1-alpha-2 - Wikipedia

Metadata

Metadata

Assignees

Labels

@aws-cdk/aws-cloudfrontRelated to Amazon CloudFrontdocumentationThis is a problem with documentation.feature-requestA feature should be added or improved.needs-triageThis issue or PR still needs to be triaged.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions