diff --git a/.gitignore b/.gitignore index 00a54a7..325ef16 100644 --- a/.gitignore +++ b/.gitignore @@ -29,6 +29,7 @@ npm-debug.log* yarn-debug.log* yarn-error.log* .pnpm-debug.log* +firebase-debug.log* # env files (can opt-in for committing if needed) .env* diff --git a/next.config.ts b/next.config.ts index dc2d4fe..6b361e8 100644 --- a/next.config.ts +++ b/next.config.ts @@ -7,10 +7,9 @@ const nextConfig: NextConfig = { // Image optimization images: { remotePatterns: [ - { - protocol: "https", - hostname: "**", - }, + { protocol: "https", hostname: "*.contabostorage.com" }, + { protocol: "https", hostname: "*.amazonaws.com" }, + { protocol: "https", hostname: "*.digitaloceanspaces.com" }, ], }, }; diff --git a/src/app/dashboard/users/[id]/page.tsx b/src/app/dashboard/users/[id]/page.tsx index 337514b..9b447fd 100644 --- a/src/app/dashboard/users/[id]/page.tsx +++ b/src/app/dashboard/users/[id]/page.tsx @@ -39,7 +39,6 @@ export default function UserDetailPage() { const [verificationHistory, setVerificationHistory] = useState([]); const [agentFieldValues, setAgentFieldValues] = useState([]); const [isTogglingStatus, setIsTogglingStatus] = useState(false); - const [pendingApprovalConfirm, setPendingApprovalConfirm] = useState(false); // Is the agent subscription active (paid)? const PAID_STATUSES = new Set(['ACTIVE', 'TRIALING', 'PAST_DUE']); @@ -189,23 +188,9 @@ export default function UserDetailPage() { } }; - const handleVerification = async ( - status: VerificationStatus, - opts?: { skipPaymentCheck?: boolean }, - ) => { + const handleVerification = async (status: VerificationStatus) => { if (!user) return; - // Guard: approving a user without active subscription requires extra confirmation - if ( - status === 'APPROVED' && - !opts?.skipPaymentCheck && - !isSubscriptionActive(user.agentProfile?.subscriptionStatus) - ) { - setPendingApprovalConfirm(true); - return; - } - - setPendingApprovalConfirm(false); setIsUpdatingVerification(true); setError(''); setUpdateSuccess(''); @@ -849,44 +834,6 @@ export default function UserDetailPage() { )} - {/* Approve-without-payment confirmation modal */} - {pendingApprovalConfirm && ( -
-
-
-

Approve Without Payment?

-
-
-

- This user has not paid for a subscription. -

-

- Approving will mark the profile as verified and it will be visible in - public search results. Payment is not required for visibility. -

-

- Are you sure you want to approve this profile anyway? -

-
-
- - -
-
-
- )} ); }