Skip to content

Type parameter when returning Scope with middleware from fn #3074

Answered by robjtede
Tipnos asked this question in Q&A
Discussion options

You must be logged in to vote

To change the default type parameter for Scopes:

fn api_service(arg_from_clap: i64) -> actix_web::Scope<
    impl ServiceFactory<
        ServiceRequest,
        Response = ServiceResponse<impl MessageBody>,
        Config = (),
        InitError = (),
        Error = actix_web::Error,
    >,
> {
    // ...
}

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by robjtede
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #3073 on July 18, 2023 16:53.