mirror of
https://github.com/actix/actix-extras.git
synced 2024-11-23 23:51:06 +01:00
relax body bounds (#223)
This commit is contained in:
parent
7bb1f8d710
commit
ab3615b8d5
@ -1,8 +1,11 @@
|
|||||||
# Changes
|
# Changes
|
||||||
|
|
||||||
## Unreleased - 2021-xx-xx
|
## Unreleased - 2021-xx-xx
|
||||||
|
- Relax body type bounds on middleware impl. [#223]
|
||||||
- Update `actix-web` dependency to `4.0.0-rc.1`.
|
- Update `actix-web` dependency to `4.0.0-rc.1`.
|
||||||
|
|
||||||
|
[#223]: https://github.com/actix/actix-extras/pull/223
|
||||||
|
|
||||||
|
|
||||||
## 0.6.0-beta.8 - 2021-12-29
|
## 0.6.0-beta.8 - 2021-12-29
|
||||||
- Minimum supported Rust version (MSRV) is now 1.54.
|
- Minimum supported Rust version (MSRV) is now 1.54.
|
||||||
|
@ -490,7 +490,6 @@ where
|
|||||||
S::Future: 'static,
|
S::Future: 'static,
|
||||||
|
|
||||||
B: MessageBody + 'static,
|
B: MessageBody + 'static,
|
||||||
B::Error: Into<Error>,
|
|
||||||
{
|
{
|
||||||
type Response = ServiceResponse<EitherBody<B>>;
|
type Response = ServiceResponse<EitherBody<B>>;
|
||||||
type Error = Error;
|
type Error = Error;
|
||||||
|
@ -143,7 +143,6 @@ where
|
|||||||
S::Future: 'static,
|
S::Future: 'static,
|
||||||
|
|
||||||
B: MessageBody + 'static,
|
B: MessageBody + 'static,
|
||||||
B::Error: Into<Error>,
|
|
||||||
{
|
{
|
||||||
type Response = ServiceResponse<EitherBody<B>>;
|
type Response = ServiceResponse<EitherBody<B>>;
|
||||||
type Error = Error;
|
type Error = Error;
|
||||||
@ -189,12 +188,19 @@ where
|
|||||||
mod tests {
|
mod tests {
|
||||||
use actix_web::{
|
use actix_web::{
|
||||||
dev::Transform,
|
dev::Transform,
|
||||||
|
middleware::Compat,
|
||||||
test::{self, TestRequest},
|
test::{self, TestRequest},
|
||||||
|
App,
|
||||||
};
|
};
|
||||||
|
|
||||||
use super::*;
|
use super::*;
|
||||||
use crate::Cors;
|
use crate::Cors;
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn compat_compat() {
|
||||||
|
let _ = App::new().wrap(Compat::new(Cors::default()));
|
||||||
|
}
|
||||||
|
|
||||||
#[actix_web::test]
|
#[actix_web::test]
|
||||||
async fn test_options_no_origin() {
|
async fn test_options_no_origin() {
|
||||||
// Tests case where allowed_origins is All but there are validate functions to run incase.
|
// Tests case where allowed_origins is All but there are validate functions to run incase.
|
||||||
|
@ -1,8 +1,11 @@
|
|||||||
# Changes
|
# Changes
|
||||||
|
|
||||||
## Unreleased - 2021-xx-xx
|
## Unreleased - 2021-xx-xx
|
||||||
|
- Relax body type bounds on middleware impl. [#223]
|
||||||
- Update `actix-web` dependency to `4.0.0-rc.1`.
|
- Update `actix-web` dependency to `4.0.0-rc.1`.
|
||||||
|
|
||||||
|
[#223]: https://github.com/actix/actix-extras/pull/223
|
||||||
|
|
||||||
|
|
||||||
## 0.4.0-beta.8 - 2022-01-21
|
## 0.4.0-beta.8 - 2022-01-21
|
||||||
- No significant changes since `0.4.0-beta.7`.
|
- No significant changes since `0.4.0-beta.7`.
|
||||||
|
@ -44,7 +44,6 @@ where
|
|||||||
S::Future: 'static,
|
S::Future: 'static,
|
||||||
T: IdentityPolicy,
|
T: IdentityPolicy,
|
||||||
B: MessageBody + 'static,
|
B: MessageBody + 'static,
|
||||||
B::Error: Into<Error>,
|
|
||||||
{
|
{
|
||||||
type Response = ServiceResponse<EitherBody<B>>;
|
type Response = ServiceResponse<EitherBody<B>>;
|
||||||
type Error = Error;
|
type Error = Error;
|
||||||
@ -80,7 +79,6 @@ where
|
|||||||
S::Future: 'static,
|
S::Future: 'static,
|
||||||
T: IdentityPolicy,
|
T: IdentityPolicy,
|
||||||
B: MessageBody + 'static,
|
B: MessageBody + 'static,
|
||||||
B::Error: Into<Error>,
|
|
||||||
{
|
{
|
||||||
type Response = ServiceResponse<EitherBody<B>>;
|
type Response = ServiceResponse<EitherBody<B>>;
|
||||||
type Error = Error;
|
type Error = Error;
|
||||||
|
@ -301,7 +301,6 @@ where
|
|||||||
S::Future: 'static,
|
S::Future: 'static,
|
||||||
S::Error: 'static,
|
S::Error: 'static,
|
||||||
B: MessageBody + 'static,
|
B: MessageBody + 'static,
|
||||||
B::Error: Into<Error>,
|
|
||||||
{
|
{
|
||||||
type Response = ServiceResponse<EitherBody<B>>;
|
type Response = ServiceResponse<EitherBody<B>>;
|
||||||
type Error = S::Error;
|
type Error = S::Error;
|
||||||
@ -329,7 +328,6 @@ where
|
|||||||
S::Future: 'static,
|
S::Future: 'static,
|
||||||
S::Error: 'static,
|
S::Error: 'static,
|
||||||
B: MessageBody + 'static,
|
B: MessageBody + 'static,
|
||||||
B::Error: Into<Error>,
|
|
||||||
{
|
{
|
||||||
type Response = ServiceResponse<EitherBody<B>>;
|
type Response = ServiceResponse<EitherBody<B>>;
|
||||||
type Error = S::Error;
|
type Error = S::Error;
|
||||||
|
@ -1,8 +1,11 @@
|
|||||||
# Changes
|
# Changes
|
||||||
|
|
||||||
## Unreleased - 2021-xx-xx
|
## Unreleased - 2021-xx-xx
|
||||||
|
- Relax body type bounds on middleware impl. [#223]
|
||||||
- Update `actix-web` dependency to `4.0.0-rc.1`.
|
- Update `actix-web` dependency to `4.0.0-rc.1`.
|
||||||
|
|
||||||
|
[#223]: https://github.com/actix/actix-extras/pull/223
|
||||||
|
|
||||||
|
|
||||||
## 0.6.0-beta.7 - 2021-12-29
|
## 0.6.0-beta.7 - 2021-12-29
|
||||||
- Minimum supported Rust version (MSRV) is now 1.54.
|
- Minimum supported Rust version (MSRV) is now 1.54.
|
||||||
|
@ -124,7 +124,6 @@ where
|
|||||||
O: Future<Output = Result<ServiceRequest, Error>> + 'static,
|
O: Future<Output = Result<ServiceRequest, Error>> + 'static,
|
||||||
T: AuthExtractor + 'static,
|
T: AuthExtractor + 'static,
|
||||||
B: MessageBody + 'static,
|
B: MessageBody + 'static,
|
||||||
B::Error: Into<Error>,
|
|
||||||
{
|
{
|
||||||
type Response = ServiceResponse<EitherBody<B>>;
|
type Response = ServiceResponse<EitherBody<B>>;
|
||||||
type Error = Error;
|
type Error = Error;
|
||||||
@ -159,7 +158,6 @@ where
|
|||||||
O: Future<Output = Result<ServiceRequest, Error>> + 'static,
|
O: Future<Output = Result<ServiceRequest, Error>> + 'static,
|
||||||
T: AuthExtractor + 'static,
|
T: AuthExtractor + 'static,
|
||||||
B: MessageBody + 'static,
|
B: MessageBody + 'static,
|
||||||
B::Error: Into<Error>,
|
|
||||||
{
|
{
|
||||||
type Response = ServiceResponse<EitherBody<B>>;
|
type Response = ServiceResponse<EitherBody<B>>;
|
||||||
type Error = S::Error;
|
type Error = S::Error;
|
||||||
|
Loading…
Reference in New Issue
Block a user