[Modify] Polish it

This commit is contained in:
sta 2020-01-12 19:35:07 +09:00
parent bfbc8ec186
commit ef2d7ac99c

View File

@ -622,8 +622,10 @@ namespace WebSocketSharp.Net
return; return;
} }
if (value.Length == 0) if (value.Length == 0) {
throw new ArgumentException ("An empty string.", "value"); var msg = "An empty string.";
throw new ArgumentException (msg, "value");
}
Uri uri; Uri uri;
if (!Uri.TryCreate (value, UriKind.Absolute, out uri)) if (!Uri.TryCreate (value, UriKind.Absolute, out uri))