fix(dashboard): rescan plugins when cached directory is removed
This commit is contained in:
@@ -4021,6 +4021,9 @@ def _get_dashboard_plugins(force_rescan: bool = False) -> list:
|
||||
global _dashboard_plugins_cache
|
||||
if _dashboard_plugins_cache is None or force_rescan:
|
||||
_dashboard_plugins_cache = _discover_dashboard_plugins()
|
||||
elif _dashboard_plugins_cache:
|
||||
if any(not Path(p["_dir"]).is_dir() for p in _dashboard_plugins_cache):
|
||||
_dashboard_plugins_cache = _discover_dashboard_plugins()
|
||||
return _dashboard_plugins_cache
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user