From ede773dd93dfaa5285aac56ce89ef2449b44e933 Mon Sep 17 00:00:00 2001 From: Armin Ronacher Date: Sun, 27 May 2018 10:49:14 -0700 Subject: [PATCH] Outdent examples --- examples/application/src/main.rs | 36 ++++++++++++++++---------------- 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/examples/application/src/main.rs b/examples/application/src/main.rs index 321b0bc..54644b9 100644 --- a/examples/application/src/main.rs +++ b/examples/application/src/main.rs @@ -6,31 +6,31 @@ mod state; fn make_app() { // - fn index(req: HttpRequest) -> impl Responder { - "Hello world!" - } +fn index(req: HttpRequest) -> impl Responder { + "Hello world!" +} - let app = App::new() - .prefix("/app") - .resource("/index.html", |r| r.method(Method::GET).f(index)) - .finish() +let app = App::new() + .prefix("/app") + .resource("/index.html", |r| r.method(Method::GET).f(index)) + .finish() // ; } fn run_server() { // - let server = server::new(|| { - vec![ - App::new() - .prefix("/app1") - .resource("/", |r| r.f(|r| HttpResponse::Ok())), - App::new() - .prefix("/app2") - .resource("/", |r| r.f(|r| HttpResponse::Ok())), - App::new().resource("/", |r| r.f(|r| HttpResponse::Ok())), - ] - }); +let server = server::new(|| { + vec![ + App::new() + .prefix("/app1") + .resource("/", |r| r.f(|r| HttpResponse::Ok())), + App::new() + .prefix("/app2") + .resource("/", |r| r.f(|r| HttpResponse::Ok())), + App::new().resource("/", |r| r.f(|r| HttpResponse::Ok())), + ] +}); // }