This commit is contained in:
Yuriy Yuriev
2026-07-05 16:59:33 +07:00
parent f262616aad
commit 44ce29d2e0
9 changed files with 188 additions and 31 deletions
+5
View File
@@ -62,6 +62,11 @@ class AuthStorage:
data = await asyncio.to_thread(self._load_sync)
return str(user_id) in data
async def get_all_user_ids(self) -> list[int]:
async with self._lock:
data = await asyncio.to_thread(self._load_sync)
return [int(k) for k in data.keys()]
def _load_sync(self) -> dict:
if not self.file_path.exists():
return {}