We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8d37edb commit dec0ff0Copy full SHA for dec0ff0
1 file changed
src/utils.ts
@@ -2,6 +2,7 @@ import type { EngineName, EngineParameters } from "./types.ts";
2
import { version } from "../version.ts";
3
import https from "node:https";
4
import qs from "node:querystring";
5
+import url from "node:url";
6
import { RequestTimeoutError } from "./errors.ts";
7
8
/**
@@ -39,7 +40,7 @@ export function extractNextParameters<E extends EngineName = EngineName>(
39
40
json["pagination"]?.["next"];
41
42
if (nextUrlString) {
- const nextUrl = new URL(nextUrlString);
43
+ const nextUrl = new url.URL(nextUrlString);
44
const nextParameters: Record<string, string> = {};
45
for (const [k, v] of nextUrl.searchParams.entries()) {
46
if (k === "engine") continue;
0 commit comments