aboutsummaryrefslogtreecommitdiff
path: root/SocketHttpListener/Net/CookieHelper.cs
diff options
context:
space:
mode:
authorAndrew Rabert <6550543+nvllsvm@users.noreply.github.com>2019-01-19 15:11:50 -0500
committerGitHub <noreply@github.com>2019-01-19 15:11:50 -0500
commit55538764fa06a64795c099fc6496df9dbb4156bd (patch)
tree8c1f94861ecebdf634b70a7265945b6f8f13aff1 /SocketHttpListener/Net/CookieHelper.cs
parent3b52035ee064a5d9aa215d9515211d4508585d39 (diff)
parentc5430f86b0b5863482e7c4f7e55a79c7d88c133b (diff)
Merge pull request #575 from EraYaN/reformat
Reformat all C# server code to conform with code standards
Diffstat (limited to 'SocketHttpListener/Net/CookieHelper.cs')
-rw-r--r--SocketHttpListener/Net/CookieHelper.cs6
1 files changed, 2 insertions, 4 deletions
diff --git a/SocketHttpListener/Net/CookieHelper.cs b/SocketHttpListener/Net/CookieHelper.cs
index 6c1764e09..3ad76ff23 100644
--- a/SocketHttpListener/Net/CookieHelper.cs
+++ b/SocketHttpListener/Net/CookieHelper.cs
@@ -1,9 +1,8 @@
-using System;
+using System;
using System.Collections.Generic;
using System.Globalization;
using System.Net;
using System.Text;
-using System.Threading.Tasks;
namespace SocketHttpListener.Net
{
@@ -44,13 +43,12 @@ namespace SocketHttpListener.Net
if (i < pairs.Length - 1)
buffer.AppendFormat(", {0}", pairs[++i].Trim());
- DateTime expires;
if (!DateTime.TryParseExact(
buffer.ToString(),
new[] { "ddd, dd'-'MMM'-'yyyy HH':'mm':'ss 'GMT'", "r" },
new CultureInfo("en-US"),
DateTimeStyles.AdjustToUniversal | DateTimeStyles.AssumeUniversal,
- out expires))
+ out var expires))
expires = DateTime.Now;
if (cookie != null && cookie.Expires == DateTime.MinValue)