From d40e402f2d0f3da238d92716b490b03cefce7477 Mon Sep 17 00:00:00 2001 From: Burak Akgerman Date: Sat, 4 Jun 2022 20:04:47 -0400 Subject: [PATCH] Change Any() to Count > 0 --- .../LayoutRenderers/AspNetResponseCookieLayoutRenderer.cs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/Shared/LayoutRenderers/AspNetResponseCookieLayoutRenderer.cs b/src/Shared/LayoutRenderers/AspNetResponseCookieLayoutRenderer.cs index f18daa64..3c8ea975 100644 --- a/src/Shared/LayoutRenderers/AspNetResponseCookieLayoutRenderer.cs +++ b/src/Shared/LayoutRenderers/AspNetResponseCookieLayoutRenderer.cs @@ -1,9 +1,7 @@ using System; using System.Collections.Generic; using System.Linq; -using System.Net.Sockets; using System.Text; -using NLog.Config; using NLog.LayoutRenderers; using NLog.Web.Enums; using NLog.Web.Internal; @@ -74,7 +72,7 @@ protected override void DoAppend(StringBuilder builder, LogEventInfo logEvent) var cookies = GetCookies(httpResponse); #if ASP_NET_CORE - if (cookies.Any()) + if (cookies.Count > 0) #else if(cookies.Count > 0) #endif