mirror of
https://github.com/home-assistant/supervisor.git
synced 2025-11-04 16:39:33 +00:00
Speedup HA core auth (#2144)
* Speedup HA core auth * Add reset API call * use delete * Add complexe cache logic * Allow manage api to handle auth reset/cache * revert to only cache * add tests * ignore protected-access for this tests * fix comment
This commit is contained in:
@@ -86,3 +86,8 @@ class APIAuth(CoreSysAttributes):
|
||||
await asyncio.shield(
|
||||
self.sys_auth.change_password(body[ATTR_USERNAME], body[ATTR_PASSWORD])
|
||||
)
|
||||
|
||||
@api_process
|
||||
async def cache(self, request: web.Request) -> None:
|
||||
"""Process cache reset request."""
|
||||
self.sys_auth.reset_data()
|
||||
|
||||
Reference in New Issue
Block a user