Bootstrap code cleanup.

This commit is contained in:
Leo Vasanko
2025-08-06 14:39:44 -06:00
parent dcca3e3fbd
commit f050dfb3f2
4 changed files with 161 additions and 171 deletions

View File

@@ -231,6 +231,15 @@ class DatabaseInterface(ABC):
) -> None:
"""Create a new user and their first credential in a transaction."""
# Bootstrap helpers
@abstractmethod
async def has_any_users(self) -> bool:
"""Check if any users exist in the system."""
@abstractmethod
async def find_users_by_role(self, role: str) -> list[User]:
"""Find all users with a specific role."""
__all__ = [
"User",