Admins could remove the admin group from, deactivate, or delete the last active admin, locking the system out of all administration. Add a count_active_admins() repo method and a _is_last_active_admin() guard, and block all three operations when they would leave zero active admins. Refs: porchlight-yq7 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| __init__.py | ||
| conftest.py | ||
| test_db.py | ||
| test_exceptions.py | ||
| test_migrations.py | ||
| test_protocols.py | ||
| test_sqlite_consent_repo.py | ||
| test_sqlite_credential_repo.py | ||
| test_sqlite_magic_link_repo.py | ||
| test_sqlite_user_repo.py | ||