Legacy Reporting Views Removed, Single Source of Truth Restored
A schema-hygiene and isolation fix, applied before launch.
Five reporting views dating from an earlier schema era have been removed. They were not used anywhere in the product, every report is computed from the base tables, but they predated the row-level security work and did not enforce per-organisation isolation, and they were a second, divergent way to compute figures the reporting layer already owns. Removing them closes the isolation gap and leaves a single source of truth for every reported number.
Why this matters
A view that quietly computes the same figures as the main reporting path, by different and unvalidated logic, is a hazard even when nothing reads it: it invites a future query to wire it in and ship numbers that disagree with the canonical path. These particular views also bypassed row-level security, so they would have returned figures across organisations rather than scoped to the caller. No report ever used them, so no data was exposed, but carrying them was a liability on both counts. Reporting now has exactly one source, the base tables, with tenant isolation enforced at the database layer.
Proof anchors
Database layer:
reporting figures are computed from the base tables, which enforce per-organisation
row-level security; the unused legacy views are removed (migration 115).
Verification:
the schema coverage gate (AX-COV-001) is unaffected, and a clean rebuild applies the
original creation and this removal in order, landing the views absent.