Add logging for http and websocket start

This commit is contained in:
Archangel
2025-02-14 15:14:19 +01:00
parent d000eaeef5
commit aa382585bd
2 changed files with 11 additions and 0 deletions
+5
View File
@@ -135,4 +135,9 @@ public class HttpServer(
{
return started;
}
public string ListeningUrl()
{
return $"http://{_httpConfig.Ip}:{_httpConfig.Port}";
}
}
+6
View File
@@ -87,6 +87,12 @@ public class App
_timer = new Timer(_ => Update(_onUpdate), null, TimeSpan.Zero, TimeSpan.FromMilliseconds(5000));
if (_httpServer.IsStarted())
{
_logger.Success(_localisationService.GetText("started_webserver_success", _httpServer.ListeningUrl()));
_logger.Success(_localisationService.GetText("websocket-started", _httpServer.ListeningUrl().Replace("http://", "ws://")));
}
_logger.Success(GetRandomisedStartMessage());
}