From 946bf20b657fd56452a6bfb08895eca55af128a9 Mon Sep 17 00:00:00 2001 From: sta Date: Sat, 18 Jan 2020 21:47:52 +0900 Subject: [PATCH] [Modify] Polish it --- websocket-sharp/Net/HttpListenerResponse.cs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/websocket-sharp/Net/HttpListenerResponse.cs b/websocket-sharp/Net/HttpListenerResponse.cs index ed6f695e..0c7b8c22 100644 --- a/websocket-sharp/Net/HttpListenerResponse.cs +++ b/websocket-sharp/Net/HttpListenerResponse.cs @@ -1090,8 +1090,10 @@ namespace WebSocketSharp.Net } Uri uri; - if (!Uri.TryCreate (url, UriKind.Absolute, out uri)) - throw new ArgumentException ("Not an absolute URL.", "url"); + if (!Uri.TryCreate (url, UriKind.Absolute, out uri)) { + var msg = "Not an absolute URL."; + throw new ArgumentException (msg, "url"); + } _redirectLocation = uri; _statusCode = 302;