Skip to content

Commit 60ac8c9

Browse files
authored
Merge pull request #64 from bing-framework/dev_3.1
发布 2.2.8
2 parents 014c2bc + 5ec4a8a commit 60ac8c9

File tree

3 files changed

+9
-5
lines changed

3 files changed

+9
-5
lines changed

framework/src/Bing.Logging/Bing/Logging/Log.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,10 @@ protected virtual void ConvertStateToContent()
269269
{
270270
if (item.Value.SafeString().IsEmpty())
271271
continue;
272-
LogProperties.Add(item.Key, item.Value);
272+
if (LogProperties.ContainsKey(item.Key))
273+
LogProperties[item.Key] = item.Value;
274+
else
275+
LogProperties.Add(item.Key, item.Value);
273276
}
274277
}
275278

framework/tests/Bing.Logging.Serilog.Tests/LogTest.cs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -113,8 +113,9 @@ public void Test_LogTrace_Message_9()
113113
_log.EventId(119)
114114
.Message("Test_LogTrace_Message_9_{id}", $"id_{Id.NewString()}")
115115
.State(new Product { Code = "a", Name = "b", Price = 123 })
116-
.Property("Age","18")
117-
.Property("Description","hello")
116+
.Property("Code", "a")
117+
.Property("Age", "18")
118+
.Property("Description", "hello")
118119
.LogTrace();
119120
}
120121

@@ -142,4 +143,4 @@ public void Test_LogTrace_Property_2()
142143
.State(new Product { Code = "a", Name = "b", Price = 123 })
143144
.LogTrace();
144145
}
145-
}
146+
}

version.props

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<PropertyGroup>
33
<VersionMajor>2</VersionMajor>
44
<VersionMinor>2</VersionMinor>
5-
<VersionPatch>7</VersionPatch>
5+
<VersionPatch>8</VersionPatch>
66
<VersionQuality>20221020-1</VersionQuality>
77
<VersionPrefix>$(VersionMajor).$(VersionMinor).$(VersionPatch)</VersionPrefix>
88
<!--<VersionSuffix>preview-$(VersionQuality)</VersionSuffix>-->

0 commit comments

Comments
 (0)