From 3a2035a121048234b8cc63215b3df248a4e60c40 Mon Sep 17 00:00:00 2001 From: Nikolay Kim Date: Sat, 9 Mar 2019 21:15:26 -0800 Subject: [PATCH] fix doc tests --- src/middleware/identity.rs | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/src/middleware/identity.rs b/src/middleware/identity.rs index 74e5f341..7cf739bc 100644 --- a/src/middleware/identity.rs +++ b/src/middleware/identity.rs @@ -26,7 +26,7 @@ //! } //! } //! -//! fn login(id: Idenity) -> HttpResponse { +//! fn login(id: Identity) -> HttpResponse { //! id.remember("User1".to_owned()); // <- remember identity //! HttpResponse::Ok().finish() //! } @@ -41,11 +41,10 @@ //! // <- create identity middleware //! CookieIdentityPolicy::new(&[0; 32]) // <- create cookie session backend //! .name("auth-cookie") -//! .secure(false)) -//! .service(web::resource("/index.html").to(index) -//! .service(web::resource("/login.html").to(login) -//! .service(web::resource("/logout.html").to(logout) -//! )); +//! .secure(false))) +//! .service(web::resource("/index.html").to(index)) +//! .service(web::resource("/login.html").to(login)) +//! .service(web::resource("/logout.html").to(logout)); //! } //! ``` use std::cell::RefCell;