# Phase 2A Verification Gate Repair

**Status:** COMPLETE  
**Date:** 2026-07-24  
**Authorization:** Brad — exact blocker messaging + App2 verification CTA

## Canonical user-verification field

**`users.certified_by_istockhomes`** (exposed on App2 `auth.me`).

App2 `autoSyncUserCertification()` sets this from:

- `email_verified = 1`
- `phone_verified = 1`
- `face_verified = 1`

Live does **not** invent another verification system. Business verification remains `franchise.status` → `certified` (Active franchisee).

## Bug fixed

Live always showed **“Business verification required…”** even when the business was verified and only the user was blocked.

## Exact blockers now

| Gate | Headline / lower message |
|------|--------------------------|
| User only | **User verification required** / `User verification required before using Istockhomes Live.` + clarifying: business already verified; stopping on user status |
| Business only | **Business verification required** / business message + clarifying user is verified |
| Both | **User and business verification required** |
| Neither business | Business required → create business CTA |

CTA: **Complete user verification in App2** → `/App2/verification.php` (existing process).

When both verified → first-use question: **What will you be using Istockhomes Live for?**

## Brad account

Local DB not reachable from this workspace (`SQLSTATE[HY000] [2002]`). Brad’s reported production state (business verified, user not) matches the **user-only** gate branch. Production re-check after deploy: Sign In → Dashboard/Go Live should show the user-only copy above.

## Files changed

- `live/includes/auth.php` — `live_auth_verification_gate()`, `live_render_verification_required_panel()`
- `live/go-live.php` — exact blockers; purpose after both verified
- `live/dashboard.php` — same gate panel
- `live/docs/PHASE2A_VERIFICATION_GATE_REPAIR.md` (this file)

## Not done (per authorization)

Streaming, payments, recording, migrations.
