diff --git a/TODO.md b/TODO.md index 1c1a0477..dac504a6 100644 --- a/TODO.md +++ b/TODO.md @@ -1,5 +1,7 @@ # TODO +- fix device section headers when members pane is small +- when promiting someone in room as admin, rank isn't updated in members list - save and restore status in accounts.json - mark accounts as offline when closing mirage - document new x11 dependnecy (auto-idle) diff --git a/src/backend/user_files.py b/src/backend/user_files.py index e2e71560..ae5690e9 100644 --- a/src/backend/user_files.py +++ b/src/backend/user_files.py @@ -206,10 +206,13 @@ class Accounts(JSONDataFile): presence: Optional[str] = None, order: Optional[int] = None, ) -> None: - """Update existing account in the config and write to disk.""" + """Update an account if found in the config file and write to disk.""" saved = await self.read() + if user_id not in saved: + return + if enabled is not None: saved[user_id]["enabled"] = enabled