mirror of
https://github.com/LBPUnion/ProjectLighthouse.git
synced 2025-08-08 04:48:44 +00:00
Ignore mystery exception on windows
This commit is contained in:
parent
0a39db4dc3
commit
a619b4b245
1 changed files with 7 additions and 2 deletions
|
@ -20,8 +20,13 @@ namespace LBPUnion.ProjectLighthouse.Logging
|
|||
string contentFile = $"{channel}{line.LineData}\n";
|
||||
string contentAll = $"[{$"{line.LoggerLevel.Name} {channel}".TrimEnd()}] {line.LineData}\n";
|
||||
|
||||
File.AppendAllText(Path.Combine(logsDirectory, line.LoggerLevel.Name.ToFileName() + ".log"), contentFile);
|
||||
File.AppendAllText(Path.Combine(logsDirectory, "all.log"), contentAll);
|
||||
try
|
||||
{
|
||||
File.AppendAllText(Path.Combine(logsDirectory, line.LoggerLevel.Name.ToFileName() + ".log"), contentFile);
|
||||
File.AppendAllText(Path.Combine(logsDirectory, "all.log"), contentAll);
|
||||
}
|
||||
catch (IOException) { } // windows, ya goofed
|
||||
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue