Skip to content

Commit d0b9d47

Browse files
committed
Only log parameter commands at the Trace level
1 parent 93e0e92 commit d0b9d47

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

dotnet/src/webdriver/Remote/HttpCommandExecutor.cs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,10 +169,14 @@ public virtual async Task<Response> ExecuteAsync(Command commandToExecute)
169169
throw new ArgumentNullException(nameof(commandToExecute), "commandToExecute cannot be null");
170170
}
171171

172-
if (_logger.IsEnabled(LogEventLevel.Debug))
172+
if (_logger.IsEnabled(LogEventLevel.Trace))
173173
{
174174
_logger.Debug($"Executing command: [{commandToExecute.SessionId}]: {commandToExecute.Name} {commandToExecute.ParametersAsJsonString}");
175175
}
176+
else if (_logger.IsEnabled(LogEventLevel.Debug))
177+
{
178+
_logger.Debug($"Executing command: [{commandToExecute.SessionId}]: {commandToExecute.Name}");
179+
}
176180

177181
HttpCommandInfo? info = this.commandInfoRepository.GetCommandInfo<HttpCommandInfo>(commandToExecute.Name);
178182
if (info == null)

0 commit comments

Comments
 (0)