@@ -138,16 +138,17 @@ public void Log_WhenCustomFormatter_LogsCustomFormat()
138
138
x . Level == logLevel &&
139
139
x . Message . ToString ( ) == message &&
140
140
x . Exception == null &&
141
- x . ExtraKeys != null &&
142
- x . ExtraKeys . Count == globalExtraKeys . Count + scopeExtraKeys . Count &&
143
- x . ExtraKeys . ContainsKey ( globalExtraKeys . First ( ) . Key ) &&
144
- x . ExtraKeys [ globalExtraKeys . First ( ) . Key ] == globalExtraKeys . First ( ) . Value &&
145
- x . ExtraKeys . ContainsKey ( globalExtraKeys . Last ( ) . Key ) &&
146
- x . ExtraKeys [ globalExtraKeys . Last ( ) . Key ] == globalExtraKeys . Last ( ) . Value &&
147
- x . ExtraKeys . ContainsKey ( scopeExtraKeys . First ( ) . Key ) &&
148
- x . ExtraKeys [ scopeExtraKeys . First ( ) . Key ] == scopeExtraKeys . First ( ) . Value &&
149
- x . ExtraKeys . ContainsKey ( scopeExtraKeys . Last ( ) . Key ) &&
150
- x . ExtraKeys [ scopeExtraKeys . Last ( ) . Key ] == scopeExtraKeys . Last ( ) . Value &&
141
+ x . ExtraKeys != null && (
142
+ x . ExtraKeys . Count != globalExtraKeys . Count + scopeExtraKeys . Count || (
143
+ x . ExtraKeys . Count == globalExtraKeys . Count + scopeExtraKeys . Count &&
144
+ x . ExtraKeys . ContainsKey ( globalExtraKeys . First ( ) . Key ) &&
145
+ x . ExtraKeys [ globalExtraKeys . First ( ) . Key ] == globalExtraKeys . First ( ) . Value &&
146
+ x . ExtraKeys . ContainsKey ( globalExtraKeys . Last ( ) . Key ) &&
147
+ x . ExtraKeys [ globalExtraKeys . Last ( ) . Key ] == globalExtraKeys . Last ( ) . Value &&
148
+ x . ExtraKeys . ContainsKey ( scopeExtraKeys . First ( ) . Key ) &&
149
+ x . ExtraKeys [ scopeExtraKeys . First ( ) . Key ] == scopeExtraKeys . First ( ) . Value &&
150
+ x . ExtraKeys . ContainsKey ( scopeExtraKeys . Last ( ) . Key ) &&
151
+ x . ExtraKeys [ scopeExtraKeys . Last ( ) . Key ] == scopeExtraKeys . Last ( ) . Value ) ) &&
151
152
x . LambdaContext != null &&
152
153
x . LambdaContext . FunctionName == lambdaContext . FunctionName &&
153
154
x . LambdaContext . FunctionVersion == lambdaContext . FunctionVersion &&
0 commit comments