aws-samples / amazon-cloudfront-secure-static-site

Create a secure static website with CloudFront for your registered domain.
Apache License 2.0
389 stars 140 forks source link

'url.parse' is deprecated #41

Closed thomasleplus closed 2 years ago

thomasleplus commented 2 years ago

'url.parse' was deprecated since v11.0.0. Use 'url.URL' constructor instead.

Issue #, if available:

Description of changes:

In the new WHATWG URL API, the URL constructor can be used to parse an URL string. And the new resulting object does not have a path field so instead we need to concatenate the pathname and search fields.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

ConnorKirk commented 2 years ago

Thanks for making a PR @thomasleplus.

This looks good to me.