diff --git a/websocket-sharp/Ext.cs b/websocket-sharp/Ext.cs
index 1f32ef8f..9eadcefd 100644
--- a/websocket-sharp/Ext.cs
+++ b/websocket-sharp/Ext.cs
@@ -1473,50 +1473,6 @@ namespace WebSocketSharp
return false;
}
- ///
- /// Determines whether the specified HTTP request is an upgrade request to
- /// switch to the specified protocol.
- ///
- ///
- /// true if is an upgrade request to
- /// switch to ; otherwise, false.
- ///
- ///
- /// A to test.
- ///
- ///
- /// A that specifies the name of the protocol.
- ///
- ///
- ///
- /// is .
- ///
- ///
- /// -or-
- ///
- ///
- /// is .
- ///
- ///
- ///
- /// is an empty string.
- ///
- public static bool IsUpgradeRequest (
- this HttpListenerRequest request, string protocol
- )
- {
- if (request == null)
- throw new ArgumentNullException ("request");
-
- if (protocol == null)
- throw new ArgumentNullException ("protocol");
-
- if (protocol.Length == 0)
- throw new ArgumentException ("An empty string.", "protocol");
-
- return request.Headers.Upgrades (protocol);
- }
-
///
/// Determines whether the specified string is a URI string.
///
diff --git a/websocket-sharp/Net/HttpListenerRequest.cs b/websocket-sharp/Net/HttpListenerRequest.cs
index fe72aa88..34d9aa8a 100644
--- a/websocket-sharp/Net/HttpListenerRequest.cs
+++ b/websocket-sharp/Net/HttpListenerRequest.cs
@@ -610,6 +610,11 @@ namespace WebSocketSharp.Net
}
}
+ internal bool IsUpgradeRequest (string protocol)
+ {
+ return _headers.Upgrades (protocol);
+ }
+
internal void SetRequestLine (string requestLine)
{
var parts = requestLine.Split (new[] { ' ' }, 3);