diff --git a/moonraker/components/authorization.py b/moonraker/components/authorization.py index ae85769..950dbdc 100644 --- a/moonraker/components/authorization.py +++ b/moonraker/components/authorization.py @@ -197,7 +197,6 @@ class Authorization: eventloop = self.server.get_event_loop() self.prune_timer = eventloop.register_timer( self._prune_conn_handler) - self.prune_timer.start(delay=PRUNE_CHECK_TIME) # Register Authorization Endpoints self.permitted_paths.add("/server/redirect") @@ -230,6 +229,9 @@ class Authorization: self.server.register_notification("authorization:user_created") self.server.register_notification("authorization:user_deleted") + async def component_init(self) -> None: + self.prune_timer.start(delay=PRUNE_CHECK_TIME) + async def _handle_apikey_request(self, web_request: WebRequest) -> str: action = web_request.get_action() if action.upper() == 'POST':