Describe the bug
- Node.js version: v18.7.0
- OS & version: Mac OS Monterey 12.4
Actual behavior
Expected error.message to be of the form (as seen in node v14.17.6):
Invalid URL: invalid-url.com
Expected behavior
We receive an error message:
Invalid URL
Without the URL included in the message
Code to reproduce
async function test () {
const { default: got } = await import('got')
return got.get('invalid-url.com')
}
function main () {
return test()
.then(res => {
console.log(res)
})
.catch(err => {
console.log(err.message)
})
}
main()
Checklist
Describe the bug
Actual behavior
Expected error.message to be of the form (as seen in node v14.17.6):
Invalid URL: invalid-url.comExpected behavior
We receive an error message:
Invalid URLWithout the URL included in the message
Code to reproduce
Checklist