diff --git a/src/Serilog.Sinks.Console/ConsoleAuditLoggerConfigurationExtensions.cs b/src/Serilog.Sinks.Console/ConsoleAuditLoggerConfigurationExtensions.cs
index 82ce5dd..6073c37 100644
--- a/src/Serilog.Sinks.Console/ConsoleAuditLoggerConfigurationExtensions.cs
+++ b/src/Serilog.Sinks.Console/ConsoleAuditLoggerConfigurationExtensions.cs
@@ -28,9 +28,6 @@ namespace Serilog
///
public static class ConsoleAuditLoggerConfigurationExtensions
{
- static readonly object DefaultSyncRoot = new object();
- const string DefaultConsoleOutputTemplate = "[{Timestamp:HH:mm:ss} {Level:u3}] {Message:lj}{NewLine}{Exception}";
-
///
/// Writes log events to .
///
@@ -55,11 +52,11 @@ public static class ConsoleAuditLoggerConfigurationExtensions
public static LoggerConfiguration Console(
this LoggerAuditSinkConfiguration sinkConfiguration,
LogEventLevel restrictedToMinimumLevel = LevelAlias.Minimum,
- string outputTemplate = DefaultConsoleOutputTemplate,
+ string outputTemplate = ConsoleLoggerConfigurationExtensions.DefaultConsoleOutputTemplate,
IFormatProvider? formatProvider = null,
LoggingLevelSwitch? levelSwitch = null,
LogEventLevel? standardErrorFromLevel = null,
- ConsoleTheme? theme = null,
+ ConsoleTheme? theme = null,
bool applyThemeToRedirectedOutput = false,
object? syncRoot = null)
{
@@ -70,7 +67,7 @@ public static LoggerConfiguration Console(
ConsoleTheme.None :
theme ?? SystemConsoleThemes.Literate;
- syncRoot ??= DefaultSyncRoot;
+ syncRoot ??= ConsoleLoggerConfigurationExtensions.DefaultSyncRoot;
var formatter = new OutputTemplateRenderer(appliedTheme, outputTemplate, formatProvider);
return sinkConfiguration.Sink(new ConsoleSink(appliedTheme, formatter, standardErrorFromLevel, syncRoot), restrictedToMinimumLevel, levelSwitch);
@@ -104,7 +101,7 @@ public static LoggerConfiguration Console(
if (sinkConfiguration is null) throw new ArgumentNullException(nameof(sinkConfiguration));
if (formatter is null) throw new ArgumentNullException(nameof(formatter));
- syncRoot ??= DefaultSyncRoot;
+ syncRoot ??= ConsoleLoggerConfigurationExtensions.DefaultSyncRoot;
return sinkConfiguration.Sink(new ConsoleSink(ConsoleTheme.None, formatter, standardErrorFromLevel, syncRoot), restrictedToMinimumLevel, levelSwitch);
}
diff --git a/src/Serilog.Sinks.Console/ConsoleLoggerConfigurationExtensions.cs b/src/Serilog.Sinks.Console/ConsoleLoggerConfigurationExtensions.cs
index e55f7a2..cca312a 100644
--- a/src/Serilog.Sinks.Console/ConsoleLoggerConfigurationExtensions.cs
+++ b/src/Serilog.Sinks.Console/ConsoleLoggerConfigurationExtensions.cs
@@ -28,8 +28,8 @@ namespace Serilog
///
public static class ConsoleLoggerConfigurationExtensions
{
- static readonly object DefaultSyncRoot = new object();
- const string DefaultConsoleOutputTemplate = "[{Timestamp:HH:mm:ss} {Level:u3}] {Message:lj}{NewLine}{Exception}";
+ internal static readonly object DefaultSyncRoot = new object();
+ internal const string DefaultConsoleOutputTemplate = "[{Timestamp:HH:mm:ss} {Level:u3}] {Message:lj}{NewLine}{Exception}";
///
/// Writes log events to .