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 287c98a commit 0ff1d88Copy full SHA for 0ff1d88
src/utils.ts
@@ -4,8 +4,6 @@ import { type EventEmitter } from 'events';
4
import { promises as fs } from 'fs';
5
import * as http from 'http';
6
import { clearTimeout, setTimeout } from 'timers';
7
-import * as url from 'url';
8
-import { URL } from 'url';
9
import { promisify } from 'util';
10
11
import { deserialize, type Document, ObjectId, resolveBSONOptions } from './bson';
@@ -1218,7 +1216,7 @@ export async function request(
1218
1216
method: 'GET',
1219
1217
timeout: 10000,
1220
json: true,
1221
- ...url.parse(uri),
+ url: new URL(uri),
1222
...options
1223
};
1224
0 commit comments