diff --git a/examples/extended_validation/src/main.rs b/examples/extended_validation/src/main.rs index 4614eacc77..22fa960365 100644 --- a/examples/extended_validation/src/main.rs +++ b/examples/extended_validation/src/main.rs @@ -63,7 +63,7 @@ fn login<'a>(user_form: Form<'a, UserLogin<'a>>) -> Result { if user.username == "Sergio" { if let Ok(StrongPassword("password")) = user.password { - Ok(Redirect::other("/user/Sergio")) + Ok(Redirect::to("/user/Sergio")) } else { Err("Wrong password!".to_string()) } diff --git a/examples/forms/src/main.rs b/examples/forms/src/main.rs index cdb8b9894e..45b410e12c 100644 --- a/examples/forms/src/main.rs +++ b/examples/forms/src/main.rs @@ -28,7 +28,7 @@ fn login<'a>(user_form: Form<'a, UserLogin<'a>>) -> Result { if user.username == "Sergio" { match user.password { - "password" => Ok(Redirect::other("/user/Sergio")), + "password" => Ok(Redirect::to("/user/Sergio")), _ => Err("Wrong password!".to_string()) } } else {