浏览代码

Merge branch 'master' of https://github.com/dotnetcore/CAP

master
Savorboard 5 年前
父节点
当前提交
c7a941c16d
共有 1 个文件被更改,包括 2 次插入7 次删除
  1. +2
    -7
      src/DotNetCore.CAP/Diagnostics/TracingHeaders.cs

+ 2
- 7
src/DotNetCore.CAP/Diagnostics/TracingHeaders.cs 查看文件

@@ -9,7 +9,7 @@ namespace DotNetCore.CAP.Diagnostics
{
public class TracingHeaders : IEnumerable<KeyValuePair<string, string>>
{
private List<KeyValuePair<string, string>> _dataStore;
private List<KeyValuePair<string, string>> _dataStore = new List<KeyValuePair<string, string>>();

public IEnumerator<KeyValuePair<string, string>> GetEnumerator()
{
@@ -23,11 +23,6 @@ namespace DotNetCore.CAP.Diagnostics

public void Add(string name, string value)
{
if (_dataStore == null)
{
_dataStore = new List<KeyValuePair<string, string>>();
}

_dataStore.Add(new KeyValuePair<string, string>(name, value));
}

@@ -46,4 +41,4 @@ namespace DotNetCore.CAP.Diagnostics
_dataStore?.Clear();
}
}
}
}

正在加载...
取消
保存