-
-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* PerSave Settings were not initialized on new game * Use Trace for default logging * Workflow fix, NuGet is being weird on WIndows workers * Build fix
- Loading branch information
Showing
9 changed files
with
45 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
21 changes: 11 additions & 10 deletions
21
src/MCM/Logger/NullMCMLogger.cs → src/MCM/Logger/DefaultMCMLogger.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,21 @@ | ||
using System; | ||
using System.Diagnostics; | ||
|
||
namespace MCM.Logger | ||
{ | ||
internal class NullMCMLogger<T> : IMCMLogger<T> | ||
internal class DefaultMCMLogger<T> : IMCMLogger<T> | ||
{ | ||
public void LogTrace(string message, params object[] args) { } | ||
public void LogInformation(string message, params object[] args) { } | ||
public void LogWarning(string message, params object[] args) { } | ||
public void LogError(Exception exception, string message, params object[] args) { } | ||
public void LogTrace(string message, params object[] args) => Trace.WriteLine(string.Format(message, args)); | ||
public void LogInformation(string message, params object[] args) => Trace.TraceInformation(message, args); | ||
public void LogWarning(string message, params object[] args) => Trace.TraceWarning(message, args); | ||
public void LogError(Exception exception, string message, params object[] args) => Trace.TraceError(message, args); | ||
} | ||
|
||
internal class NullMCMLogger : IMCMLogger | ||
internal class DefaultMCMLogger : IMCMLogger | ||
{ | ||
public void LogTrace(string message, params object[] args) { } | ||
public void LogInformation(string message, params object[] args) { } | ||
public void LogWarning(string message, params object[] args) { } | ||
public void LogError(Exception exception, string message, params object[] args) { } | ||
public void LogTrace(string message, params object[] args) => Trace.WriteLine(string.Format(message, args)); | ||
public void LogInformation(string message, params object[] args) => Trace.TraceInformation(message, args); | ||
public void LogWarning(string message, params object[] args) => Trace.TraceWarning(message, args); | ||
public void LogError(Exception exception, string message, params object[] args) => Trace.TraceError(message, args); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters