This commit is contained in:
Han Xiao
2025-03-11 15:10:17 +08:00

View File

@@ -33,6 +33,10 @@ export async function serperSearchOld(query: string): Promise<{ response: Serper
timeout: 10000 timeout: 10000
}); });
if (response.status !== 200) {
throw new Error(`Serper search failed: ${response.status} ${response.statusText}`)
}
// Maintain the same return structure as the original code // Maintain the same return structure as the original code
return { response: response.data }; return { response: response.data };
} }