mirror of https://github.com/fafhrd91/actix-web
docs: update changelog
This commit is contained in:
parent
6baaf927d2
commit
cc5c22b674
|
@ -6,6 +6,7 @@
|
||||||
- Improve handling of non-UTF-8 header values in `Logger` middleware.
|
- Improve handling of non-UTF-8 header values in `Logger` middleware.
|
||||||
- Add `HttpServer::shutdown_signal()` method.
|
- Add `HttpServer::shutdown_signal()` method.
|
||||||
- Mark `HttpServer` as `#[must_use]`.
|
- Mark `HttpServer` as `#[must_use]`.
|
||||||
|
- Ignore `Host` header in `Host` guard when connection protocol is HTTP/2.
|
||||||
- Re-export `mime` dependency.
|
- Re-export `mime` dependency.
|
||||||
- Update `brotli` dependency to `8`.
|
- Update `brotli` dependency to `8`.
|
||||||
|
|
||||||
|
@ -28,7 +29,6 @@
|
||||||
- On Windows, an error is now returned from `HttpServer::bind()` (or TLS variants) when binding to a socket that's already in use.
|
- On Windows, an error is now returned from `HttpServer::bind()` (or TLS variants) when binding to a socket that's already in use.
|
||||||
- Update `brotli` dependency to `7`.
|
- Update `brotli` dependency to `7`.
|
||||||
- Minimum supported Rust version (MSRV) is now 1.75.
|
- Minimum supported Rust version (MSRV) is now 1.75.
|
||||||
- Guard Host does not use Host header anymore when on HTTP/2, it only use authority pseudo header.
|
|
||||||
|
|
||||||
## 4.9.0
|
## 4.9.0
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
use actix_http::{header, uri::Uri, RequestHead};
|
use actix_http::{header, uri::Uri, RequestHead, Version};
|
||||||
|
|
||||||
use super::{Guard, GuardContext};
|
use super::{Guard, GuardContext};
|
||||||
|
|
||||||
|
@ -66,7 +66,7 @@ fn get_host_uri(req: &RequestHead) -> Option<Uri> {
|
||||||
req.headers
|
req.headers
|
||||||
.get(header::HOST)
|
.get(header::HOST)
|
||||||
.and_then(|host_value| host_value.to_str().ok())
|
.and_then(|host_value| host_value.to_str().ok())
|
||||||
.filter(|_| req.version < actix_http::Version::HTTP_2)
|
.filter(|_| req.version < Version::HTTP_2)
|
||||||
.or_else(|| req.uri.host())
|
.or_else(|| req.uri.host())
|
||||||
.and_then(|host| host.parse().ok())
|
.and_then(|host| host.parse().ok())
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue