Get admin configuration
(self)
| 1335 | |
| 1336 | # Config operations |
| 1337 | async def get_admin_config(self) -> Optional[AdminConfig]: |
| 1338 | """Get admin configuration""" |
| 1339 | async with self._connect() as db: |
| 1340 | db.row_factory = aiosqlite.Row |
| 1341 | cursor = await db.execute("SELECT * FROM admin_config WHERE id = 1") |
| 1342 | row = await cursor.fetchone() |
| 1343 | if row: |
| 1344 | return AdminConfig(**dict(row)) |
| 1345 | return None |
| 1346 | |
| 1347 | async def update_admin_config(self, **kwargs): |
| 1348 | """Update admin configuration""" |
no test coverage detected