We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
When compiling the program, it prompts: error[E0277]: the trait bound fn(axum::extract::State<Arc<AppState>>, axum::Json<RegisterUserSchema>) -> impl std::future::Future<Output = Result<impl IntoResponse, (axum::http::StatusCode, axum::Json<JsonValue>)>> {register_user_handler}: Handler<_, _, _> is not satisfied --> src/route.rs:21:43 | 21 | .route("/api/auth/register", post(register_user_handler)) | ---- ^^^^^^^^^^^^^^^^^^^^^ the trait Handler<_, _, _> is not implemented for fn item fn(axum::extract::State<Arc<AppState>>, axum::Json<RegisterUserSchema>) -> impl std::future::Future<Output = Result<impl IntoResponse, (axum::http::StatusCode, axum::Json<JsonValue>)>> {register_user_handler} | | | required by a bound introduced by this call | = help: the following other types implement trait Handler<T, S, B>: <Or<L, R, Lt, Rt, S, B> as Handler<(M, Lt, Rt), S, B>> <IntoHandler<H, T, S, B> as Handler<T, S, B>> <Layered<L, H, T, S, B, B2> as Handler<T, S, B2>> <MethodRouter<S, B> as Handler<(), S, B>>
fn(axum::extract::State<Arc<AppState>>, axum::Json<RegisterUserSchema>) -> impl std::future::Future<Output = Result<impl IntoResponse, (axum::http::StatusCode, axum::Json<JsonValue>)>> {register_user_handler}: Handler<_, _, _>
Handler<_, _, _>
fn(axum::extract::State<Arc<AppState>>, axum::Json<RegisterUserSchema>) -> impl std::future::Future<Output = Result<impl IntoResponse, (axum::http::StatusCode, axum::Json<JsonValue>)>> {register_user_handler}
Handler<T, S, B>
The text was updated successfully, but these errors were encountered:
have you tried changing impl IntoResponse to UserResponse?
Sorry, something went wrong.
No branches or pull requests
When compiling the program, it prompts:
error[E0277]: the trait bound
fn(axum::extract::State<Arc<AppState>>, axum::Json<RegisterUserSchema>) -> impl std::future::Future<Output = Result<impl IntoResponse, (axum::http::StatusCode, axum::Json<JsonValue>)>> {register_user_handler}: Handler<_, _, _>
is not satisfied--> src/route.rs:21:43
|
21 | .route("/api/auth/register", post(register_user_handler))
| ---- ^^^^^^^^^^^^^^^^^^^^^ the trait
Handler<_, _, _>
is not implemented for fn itemfn(axum::extract::State<Arc<AppState>>, axum::Json<RegisterUserSchema>) -> impl std::future::Future<Output = Result<impl IntoResponse, (axum::http::StatusCode, axum::Json<JsonValue>)>> {register_user_handler}
| |
| required by a bound introduced by this call
|
= help: the following other types implement trait
Handler<T, S, B>
:<Or<L, R, Lt, Rt, S, B> as Handler<(M, Lt, Rt), S, B>>
<IntoHandler<H, T, S, B> as Handler<T, S, B>>
<Layered<L, H, T, S, B, B2> as Handler<T, S, B2>>
<MethodRouter<S, B> as Handler<(), S, B>>
The text was updated successfully, but these errors were encountered: