Skip to content

Commit a6b711c

Browse files
committed
style: 更新注释内容
1 parent 1a0d13e commit a6b711c

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

framework/src/Bing.Logging/Bing/Logging/LogContext.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ public class LogContext
6767
/// <summary>
6868
/// 标签列表
6969
/// </summary>
70-
public List<string> Tags { get; set; } = new List<string>();
70+
public List<string> Tags { get; set; } = new();
7171

7272
/// <summary>
7373
/// 扩展数据
@@ -78,7 +78,7 @@ public class LogContext
7878
/// 当前日志上下文
7979
/// </summary>
8080
// ReSharper disable once InconsistentNaming
81-
private static readonly AsyncLocal<LogContext> _current = new AsyncLocal<LogContext>();
81+
private static readonly AsyncLocal<LogContext> _current = new();
8282

8383
/// <summary>
8484
/// 当前日志上下文

framework/src/Bing.Logging/Bing/Logging/LogContextAccessor.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ public LogContext Context
3131
/// <summary>
3232
/// 创建日志上下文
3333
/// </summary>
34-
protected virtual LogContext Create() => new LogContext { TraceId = GetTraceId(), Stopwatch = GetStopwatch(), Host = Dns.GetHostName() };
34+
protected virtual LogContext Create() => new() { TraceId = GetTraceId(), Stopwatch = GetStopwatch(), Host = Dns.GetHostName() };
3535

3636
/// <summary>
3737
/// 获取跟踪标识

0 commit comments

Comments
 (0)