Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 1 addition & 15 deletions app/diagnostic/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,6 @@ import { notFound } from 'next/navigation';
import { createServer } from '@/lib/supabase/server';

export default async function DiagnosticPage() {
restrict-diagnostic-page

// Restrict diagnostic page in production
if (process.env.NODE_ENV === 'production') {
return (
<div className="min-h-screen flex items-center justify-center">
<h1 className="text-2xl font-bold">
Access Denied
</h1>
</div>
);
}
const supabase = createClient();

const diagnosticsEnabled =
process.env.NODE_ENV !== 'production' &&
process.env.ENABLE_DIAGNOSTIC_PAGE === 'true';
Expand All @@ -24,7 +10,7 @@ export default async function DiagnosticPage() {
notFound();
}

main
const supabase = await createServer();

// Check if tables exist by trying to query them
let tablesStatus = {
Expand Down
Loading