From 2bfaa0422cac7018d8f4bea1808c358ccd6b3c3f Mon Sep 17 00:00:00 2001 From: sta Date: Mon, 7 Sep 2020 21:20:25 +0900 Subject: [PATCH] [Modify] Polish it --- websocket-sharp/Net/HttpListenerPrefix.cs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/websocket-sharp/Net/HttpListenerPrefix.cs b/websocket-sharp/Net/HttpListenerPrefix.cs index fbc0697f..1f166b00 100644 --- a/websocket-sharp/Net/HttpListenerPrefix.cs +++ b/websocket-sharp/Net/HttpListenerPrefix.cs @@ -174,23 +174,23 @@ namespace WebSocketSharp.Net throw new ArgumentException (msg, "uriPrefix"); } - var startHost = uriPrefix.IndexOf (':') + 3; + var host = uriPrefix.IndexOf (':') + 3; - if (startHost >= len) { + if (host >= len) { var msg = "No host is specified."; throw new ArgumentException (msg, "uriPrefix"); } - if (uriPrefix[startHost] == ':') { + if (uriPrefix[host] == ':') { var msg = "No host is specified."; throw new ArgumentException (msg, "uriPrefix"); } - var root = uriPrefix.IndexOf ('/', startHost, len - startHost); + var root = uriPrefix.IndexOf ('/', host, len - host); - if (root == startHost) { + if (root == host) { var msg = "No host is specified."; throw new ArgumentException (msg, "uriPrefix");