6cd3743b44
This commit also ensures that the correct implementation is used on environments that do not support `URL` (e.g. Node.js). PR Close #27080