diff --git a/src/app/(app)/auto-triage/AutoTriagePageClient.tsx b/src/app/(app)/auto-triage/AutoTriagePageClient.tsx
index 794deba21..3dc926691 100644
--- a/src/app/(app)/auto-triage/AutoTriagePageClient.tsx
+++ b/src/app/(app)/auto-triage/AutoTriagePageClient.tsx
@@ -29,7 +29,9 @@ export function AutoTriagePageClient({
const trpc = useTRPC();
// Fetch GitHub App installation status
- const { data: statusData } = useQuery(trpc.personalAutoTriage.getGitHubStatus.queryOptions());
+ const { data: statusData, isLoading: isStatusLoading } = useQuery(
+ trpc.personalAutoTriage.getGitHubStatus.queryOptions()
+ );
const isGitHubAppInstalled = statusData?.connected && statusData?.integration?.isValid;
@@ -51,7 +53,7 @@ export function AutoTriagePageClient({
Auto Triage
- new
+ beta
Automatically triage GitHub issues with Al-powered analysis
@@ -68,7 +70,7 @@ export function AutoTriagePageClient({
{/* GitHub App Required Alert */}
- {!isGitHubAppInstalled && (
+ {!isStatusLoading && !isGitHubAppInstalled && (
GitHub App Required
@@ -97,7 +99,7 @@ export function AutoTriagePageClient({
Tickets
@@ -111,7 +113,7 @@ export function AutoTriagePageClient({
{/* Tickets Tab */}
- {isGitHubAppInstalled ? (
+ {isStatusLoading || isGitHubAppInstalled ? (
) : (
diff --git a/src/app/(app)/auto-triage/page.tsx b/src/app/(app)/auto-triage/page.tsx
index d3b2b5d57..d2daf867e 100644
--- a/src/app/(app)/auto-triage/page.tsx
+++ b/src/app/(app)/auto-triage/page.tsx
@@ -1,7 +1,5 @@
import { getUserFromAuthOrRedirect } from '@/lib/user.server';
import { AutoTriagePageClient } from './AutoTriagePageClient';
-import { isFeatureFlagEnabled } from '@/lib/posthog-feature-flags';
-import { notFound } from 'next/navigation';
type AutoTriagePageProps = {
searchParams: Promise<{ success?: string; error?: string }>;
@@ -11,14 +9,6 @@ export default async function PersonalAutoTriagePage({ searchParams }: AutoTriag
const search = await searchParams;
const user = await getUserFromAuthOrRedirect('/users/sign_in?callbackPath=/auto-triage');
- // Feature flags - use server-side check with user ID as distinct ID
- const isAutoTriageFeatureEnabled = await isFeatureFlagEnabled('auto-triage-feature', user.id);
- const isDevelopment = process.env.NODE_ENV === 'development';
-
- if (!isAutoTriageFeatureEnabled && !isDevelopment) {
- return notFound();
- }
-
return (
{/* GitHub App Required Alert */}
- {!isGitHubAppInstalled && (
+ {!isStatusLoading && !isGitHubAppInstalled && (
GitHub App Required
@@ -101,7 +101,7 @@ export function AutoTriagePageClient({
Tickets
@@ -115,7 +115,7 @@ export function AutoTriagePageClient({
{/* Tickets Tab */}
- {isGitHubAppInstalled ? (
+ {isStatusLoading || isGitHubAppInstalled ? (
) : (
diff --git a/src/app/(app)/organizations/[id]/auto-triage/page.tsx b/src/app/(app)/organizations/[id]/auto-triage/page.tsx
index 606c5d19e..f2f3b1372 100644
--- a/src/app/(app)/organizations/[id]/auto-triage/page.tsx
+++ b/src/app/(app)/organizations/[id]/auto-triage/page.tsx
@@ -1,7 +1,5 @@
import { OrganizationByPageLayout } from '@/components/organizations/OrganizationByPageLayout';
-import { notFound } from 'next/navigation';
import { AutoTriagePageClient } from './AutoTriagePageClient';
-import { isFeatureFlagEnabled } from '@/lib/posthog-feature-flags';
type AutoTriagePageProps = {
params: Promise<{ id: string }>;
@@ -9,20 +7,8 @@ type AutoTriagePageProps = {
};
export default async function AutoTriagePage({ params, searchParams }: AutoTriagePageProps) {
- const { id: organizationId } = await params;
const search = await searchParams;
- // Feature flags - use server-side check with organization ID as distinct ID
- const isAutoTriageFeatureEnabled = await isFeatureFlagEnabled(
- 'auto-triage-feature',
- organizationId
- );
- const isDevelopment = process.env.NODE_ENV === 'development';
-
- if (!isAutoTriageFeatureEnabled && !isDevelopment) {
- return notFound();
- }
-
return (