diff --git a/Logger/SimApiLogger.cs b/Logger/SimApiLogger.cs index ea5d9a1..bd2a5d8 100644 --- a/Logger/SimApiLogger.cs +++ b/Logger/SimApiLogger.cs @@ -13,7 +13,7 @@ public class SimApiLogger(string name) : ILogger public void Log(LogLevel logLevel, EventId eventId, TState state, Exception exception, Func formatter) { - var color = logLevel switch + Console.ForegroundColor = logLevel switch { LogLevel.Debug => ConsoleColor.DarkMagenta, LogLevel.Information => ConsoleColor.DarkCyan, @@ -29,6 +29,7 @@ public class SimApiLogger(string name) : ILogger message += $"{exception}\n"; } - Console.WriteLine(message, color); + Console.WriteLine(message); + Console.ResetColor(); } } \ No newline at end of file