[Modify] Polish it

This commit is contained in:
sta 2019-02-19 21:49:03 +09:00
parent 884ac97de8
commit 28684d8bdf

View File

@ -108,7 +108,6 @@ namespace WebSocketSharp.Net
_expires = DateTime.MinValue; _expires = DateTime.MinValue;
_name = String.Empty; _name = String.Empty;
_path = String.Empty; _path = String.Empty;
_port = String.Empty;
_timestamp = DateTime.Now; _timestamp = DateTime.Now;
_value = String.Empty; _value = String.Empty;
_version = 0; _version = 0;
@ -478,12 +477,12 @@ namespace WebSocketSharp.Net
/// </exception> /// </exception>
public string Port { public string Port {
get { get {
return _port; return _port ?? String.Empty;
} }
set { set {
if (value.IsNullOrEmpty ()) { if (value.IsNullOrEmpty ()) {
_port = String.Empty; _port = value;
_ports = null; _ports = null;
return; return;