Open-source, secure environment with real-world tools for enterprise-grade agents.
Python agentaiai-agentai-agentscode-interpretercopilotdevelopmentdevtoolsgptgpt-4javascriptllmnextjsopenaipythonreactsoftwaretypescript
Remove unnecessary URL replace rule
Vasek Mlejnskye7940c0e30e5
diff --git a/apps/web/src/middleware.ts b/apps/web/src/middleware.tsindex b30e486f0..40c6c1af9 100644--- a/apps/web/src/middleware.ts+++ b/apps/web/src/middleware.ts@@ -55,14 +55,6 @@ export async function middleware(req: NextRequest): Promise<NextResponse> {url.hostname = blogFramerHostname}- // if (url.pathname === '/changelog' || url.pathname === '/changelog/') {- // url.pathname = '/'- // url.hostname = changelogFramerHostname- // }- // if (url.pathname.startsWith('/changelog')) {- // url.hostname = changelogFramerHostname- // }-const res = await fetch(url.toString(), { ...req })const htmlBody = await res.text()diff --git a/apps/web/src/utils/replaceUrls.ts b/apps/web/src/utils/replaceUrls.tsindex 0180f6650..c3e422180 100644--- a/apps/web/src/utils/replaceUrls.ts+++ b/apps/web/src/utils/replaceUrls.ts@@ -2,7 +2,6 @@ import {landingPageHostname,landingPageFramerHostname,blogFramerHostname,- changelogFramerHostname,} from '@/app/hostnames'export function replaceUrls(text: string, urlPathName: string, prefix: string = '', suffix: string = ''): string {@@ -28,12 +27,4 @@ export function replaceUrls(text: string, urlPathName: string, prefix: string =? `${prefix}https://e2b.dev/blog`: `${prefix}https://e2b.dev`)- .replaceAll(- `${prefix}${changelogFramerHostname}`,- // The default url on framer does not have /changelog in the path but the custom domain does,- // so we need to handle this explicitly.- urlPathName === '/'- ? `${prefix}https://e2b.dev/changelog`- : `${prefix}https://e2b.dev`- )}\ No newline at end of file