1
0
mirror of https://github.com/fafhrd91/actix-web synced 2024-11-24 08:22:59 +01:00

fix Scope::handler doc test

This commit is contained in:
Nikolay Kim 2018-09-02 08:51:26 -07:00
parent 968c81e267
commit b7a73e0a4f

View File

@ -304,7 +304,7 @@ impl<S: 'static> Scope<S> {
/// ///
/// fn main() { /// fn main() {
/// let app = App::new().scope("/scope-prefix", |scope| { /// let app = App::new().scope("/scope-prefix", |scope| {
/// handler("/app", |req: &HttpRequest| match *req.method() { /// scope.handler("/app", |req: &HttpRequest| match *req.method() {
/// http::Method::GET => HttpResponse::Ok(), /// http::Method::GET => HttpResponse::Ok(),
/// http::Method::POST => HttpResponse::MethodNotAllowed(), /// http::Method::POST => HttpResponse::MethodNotAllowed(),
/// _ => HttpResponse::NotFound(), /// _ => HttpResponse::NotFound(),