fix: ci fixes, tenant router debug, select width improvement
This commit is contained in:
@@ -2,8 +2,7 @@ import * as Sentry from '@sentry/sveltekit';
|
||||
import { dev } from '$app/environment';
|
||||
import { env } from '$env/dynamic/public';
|
||||
|
||||
const isEnabled = () =>
|
||||
Boolean(env.PUBLIC_SENTRY_DSN?.trim()) && !dev && env.PUBLIC_IS_SELFHOSTED !== 'true';
|
||||
const isEnabled = () => Boolean(env.PUBLIC_SENTRY_DSN?.trim()) && !dev && env.PUBLIC_IS_SELFHOSTED !== 'true';
|
||||
|
||||
export type SentryUser = {
|
||||
id: string;
|
||||
|
||||
@@ -75,11 +75,19 @@ export default {
|
||||
upstreamHeaders.set('x-forwarded-for', clientIp);
|
||||
}
|
||||
|
||||
return fetch(upstreamUrl.toString(), {
|
||||
const upstreamResponse = await fetch(upstreamUrl.toString(), {
|
||||
method: request.method,
|
||||
headers: upstreamHeaders,
|
||||
body: request.body,
|
||||
redirect: 'manual'
|
||||
});
|
||||
|
||||
if (isProxiedApiCall) {
|
||||
console.log(
|
||||
`[proxy] ${request.method} ${url.pathname} → ${upstreamHost}${upstreamPath} status=${upstreamResponse.status} ct=${request.headers.get('content-type') ?? ''}`
|
||||
);
|
||||
}
|
||||
|
||||
return upstreamResponse;
|
||||
}
|
||||
} satisfies ExportedHandler<Env>;
|
||||
|
||||
Reference in New Issue
Block a user