mirror of
https://github.com/GitbookIO/gitbook.git
synced 2026-10-07 22:02:23 +00:00
Record proxied sites' markdown, llms.txt and RSS requests under their public URL (#4660)
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
---
|
||||
"gitbook": patch
|
||||
---
|
||||
|
||||
Track server-side Insights events (markdown, llms.txt, RSS, ask) with the site's public URL instead of the proxy URL.
|
||||
@@ -508,7 +508,8 @@ async function serveSiteRoutes(requestURL: URL, request: NextRequest) {
|
||||
siteId: siteURLData.site,
|
||||
events,
|
||||
request: {
|
||||
url: siteRequestURL.toString(),
|
||||
// A proxied site's request URL is the proxy's (`/sites/site_xxx/...`), not its public one.
|
||||
url: siteCanonicalURL.toString(),
|
||||
headers: requestHeaders,
|
||||
},
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user