axum/axum-macros/tests/from_request/pass/container.rs
David Pedersen 4e4c29175f Remove B type param (#1751)
Co-authored-by: Jonas Platte <jplatte+git@posteo.de>
Co-authored-by: Michael Scofield <mscofield0@tutanota.com>
2023-04-21 17:45:31 +02:00

21 lines
334 B
Rust

use axum::{
extract::{FromRequest, Json},
response::Response,
};
use serde::Deserialize;
#[derive(Deserialize, FromRequest)]
#[from_request(via(Json))]
struct Extractor {
one: i32,
two: String,
three: bool,
}
fn assert_from_request()
where
Extractor: FromRequest<(), Rejection = Response>,
{
}
fn main() {}