mirror of
https://github.com/dergigi/boris.git
synced 2026-02-23 16:04:29 +01:00
fix: correct Jina AI Reader proxy URL format
- Remove hardcoded http:// prefix in proxy URL - Preserve original protocol (http/https) when constructing proxy URL - Fix: https://r.jina.ai/https://example.com instead of /http://example.com - Resolves metadata fetching issues for HTTPS URLs
This commit is contained in:
@@ -57,7 +57,7 @@ function saveToCache(url: string, content: ReadableContent): void {
|
||||
function toProxyUrl(url: string): string {
|
||||
// Ensure the target URL has a protocol and build the proxy URL
|
||||
const normalized = /^https?:\/\//i.test(url) ? url : `https://${url}`
|
||||
return `https://r.jina.ai/http://${normalized.replace(/^https?:\/\//, '')}`
|
||||
return `https://r.jina.ai/${normalized}`
|
||||
}
|
||||
|
||||
export async function fetchReadableContent(
|
||||
|
||||
Reference in New Issue
Block a user