Reuse form values
This commit is contained in:
parent
74254aed4a
commit
6498dbfbb7
@ -206,11 +206,8 @@ pub fn signup(
|
|||||||
let mut err = ValidationErrors::default();
|
let mut err = ValidationErrors::default();
|
||||||
err.add("email", ValidationError::new("Email couldn't changed"));
|
err.add("email", ValidationError::new("Email couldn't changed"));
|
||||||
let form = NewUserForm {
|
let form = NewUserForm {
|
||||||
username: form.username.clone(),
|
|
||||||
password: form.password.clone(),
|
|
||||||
password_confirmation: form.password_confirmation.clone(),
|
|
||||||
email: signup.email,
|
email: signup.email,
|
||||||
token: form.token.clone(),
|
..form.into_inner()
|
||||||
};
|
};
|
||||||
return Ok(Response(render!(email_signups::edit(
|
return Ok(Response(render!(email_signups::edit(
|
||||||
&(&conn, &rockets).to_context(),
|
&(&conn, &rockets).to_context(),
|
||||||
|
Loading…
Reference in New Issue
Block a user