We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5b5f5f9 commit 4efc5f6Copy full SHA for 4efc5f6
1 file changed
lib/internal/url.js
@@ -1391,8 +1391,7 @@ function pathToFileURL(filepath) {
1391
}
1392
1393
function isURLInstance(fileURLOrPath) {
1394
- return fileURLOrPath != null && fileURLOrPath[searchParams] &&
1395
- fileURLOrPath[searchParams][searchParams];
+ return fileURLOrPath != null && fileURLOrPath.href && fileURLOrPath.origin;
1396
1397
1398
function toPathIfFileURL(fileURLOrPath) {
0 commit comments