From d732d88ba20784389fc781e3a2a0032b97375567 Mon Sep 17 00:00:00 2001 From: sta Date: Fri, 1 Mar 2019 21:43:54 +0900 Subject: [PATCH] [Modify] Polish it --- websocket-sharp/Net/Cookie.cs | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/websocket-sharp/Net/Cookie.cs b/websocket-sharp/Net/Cookie.cs index 97487956..4c9f1297 100644 --- a/websocket-sharp/Net/Cookie.cs +++ b/websocket-sharp/Net/Cookie.cs @@ -361,14 +361,8 @@ namespace WebSocketSharp.Net } set { - if (value.IsNullOrEmpty ()) { - _domain = String.Empty; - ExactDomain = true; - } - else { - _domain = value; - ExactDomain = value[0] != '.'; - } + _domain = value ?? String.Empty; + ExactDomain = _domain.Length == 0 || _domain[0] != '.'; } }