From d15737f004e3a94fd0c047800abf02df480ec35f Mon Sep 17 00:00:00 2001 From: "Alecio Furanze (Ale)" Date: Sun, 23 Jun 2024 11:38:00 +0200 Subject: [PATCH] remove StatusCode from HTTP.ServerRequest.cs --- src/http/interfaces/IHTTP.ServerRequest.cs | 7 ------- .../Server/{HTTP.Request.cs => HTTP.ServerRequest.cs} | 8 -------- 2 files changed, 15 deletions(-) rename src/http/partials/Server/{HTTP.Request.cs => HTTP.ServerRequest.cs} (97%) diff --git a/src/http/interfaces/IHTTP.ServerRequest.cs b/src/http/interfaces/IHTTP.ServerRequest.cs index 21a83b0d..e56bae9c 100644 --- a/src/http/interfaces/IHTTP.ServerRequest.cs +++ b/src/http/interfaces/IHTTP.ServerRequest.cs @@ -83,13 +83,6 @@ public interface ServerRequest /// Request Enctype /// HTTP.Enctype Enctype { get; } - - - /// - /// Http Status Code.
- /// if value is -1 mean: (not applicable on context). - ///
- int Status { get; } } } } \ No newline at end of file diff --git a/src/http/partials/Server/HTTP.Request.cs b/src/http/partials/Server/HTTP.ServerRequest.cs similarity index 97% rename from src/http/partials/Server/HTTP.Request.cs rename to src/http/partials/Server/HTTP.ServerRequest.cs index 2038245a..728c9872 100644 --- a/src/http/partials/Server/HTTP.Request.cs +++ b/src/http/partials/Server/HTTP.ServerRequest.cs @@ -41,8 +41,6 @@ internal ServerRequest(HttpListenerRequest request) } { - Status = -1; - Method = new HttpMethod(request.HttpMethod); Url = request.Url.AbsoluteUri; @@ -98,9 +96,6 @@ internal ServerRequest(ClientWebSocket ws, Uri uri, Dictionary h } { - // Not applicable - Status = -1; - // Not applicable Method = HttpMethod.Get; @@ -173,8 +168,6 @@ internal ServerRequest(HttpResponseMessage message) } { - Status = (int)message.StatusCode; - Method = message.RequestMessage.Method; Url = uri.AbsoluteUri; @@ -216,7 +209,6 @@ internal ServerRequest(HttpResponseMessage message) public bool IsEncrypted { get; } public IHTTP.Body Body { get; } public Enctype Enctype => Body.Enctype; - public int Status { get; } /// /// Set queries from an exist uri