moonraker: perform install validation
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
This commit is contained in:
parent
6e56815b42
commit
5259a6fd0a
|
@ -40,6 +40,7 @@ from typing import (
|
|||
if TYPE_CHECKING:
|
||||
from websockets import WebRequest, WebsocketManager
|
||||
from components.file_manager.file_manager import FileManager
|
||||
from components.machine import Machine
|
||||
FlexCallback = Callable[..., Optional[Coroutine]]
|
||||
_T = TypeVar("_T")
|
||||
|
||||
|
@ -162,6 +163,10 @@ class Server:
|
|||
if not self.warnings:
|
||||
await self.event_loop.run_in_thread(self.config.create_backup)
|
||||
|
||||
machine: Machine = self.lookup_component("machine")
|
||||
if await machine.validate_installation():
|
||||
return
|
||||
|
||||
if start_server:
|
||||
await self.start_server()
|
||||
|
||||
|
|
Loading…
Reference in New Issue