fix(search): guard params.token undefined in serper headers (typecheck base-red)

This commit is contained in:
backryun
2026-08-12 01:19:08 -03:00
parent 8a35c45029
commit 78a5ce5cea

View File

@@ -304,7 +304,7 @@ function buildSerperRequest(
url: `${config.baseUrl}${endpoint}`,
init: {
method: "POST",
headers: { "Content-Type": "application/json", "X-API-Key": params.token },
headers: { "Content-Type": "application/json", "X-API-Key": params.token ?? "" },
body: JSON.stringify(body),
},
};