twilio-node
twilio-node copied to clipboard
feat: move to built-in URL class
We currently use url-parse
to deal with URL construction. Given our node engine constraint of >=14
, we know URL
is available in all supported node versions (introduced in 10.x
if i remember correctly).
So we should be able to drop this dependency and use the built-in parser instead.
Note that one test here changed hash because url-parse incorrectly did not encode the single quotes in the test URL. With the standard URL
parsing, it is now encoded.
Let me know if there's anything you want me to change here. Also, if someone could confirm i updated the test hash correctly, that'd be very helpful.
Checklist
- [x] I acknowledge that all my contributions will be made under the project's license
- [x] I have made a material change to the repo (functionality, testing, spelling, grammar)
- [x] I have read the Contribution Guidelines and my PR follows them
- [x] I have titled the PR appropriately
- [x] I have updated my branch with the main branch
- [x] I have added tests that prove my fix is effective or that my feature works
- [ ] I have added the necessary documentation about the functionality in the appropriate .md file
- [ ] I have added inline documentation to the code I modified