mirror of
https://github.com/danbulant/Portfolio
synced 2026-07-05 11:00:56 +00:00
fix: candidate password reset
This commit is contained in:
parent
9f35f6fa89
commit
d3705a3ed0
1 changed files with 6 additions and 2 deletions
|
|
@ -115,9 +115,13 @@ impl CandidateService {
|
||||||
new_password_plain.to_string()
|
new_password_plain.to_string()
|
||||||
).await?;
|
).await?;
|
||||||
|
|
||||||
|
|
||||||
Self::delete_old_sessions(db, candidate.clone(), 0).await?;
|
Self::delete_old_sessions(db, candidate.clone(), 0).await?;
|
||||||
Mutation::update_candidate_password_and_keys(db, candidate.clone(), new_password_hash, pubkey, encrypted_priv_key).await?;
|
let candidate = Mutation::update_candidate_password_and_keys(db,
|
||||||
|
candidate,
|
||||||
|
new_password_hash,
|
||||||
|
pubkey,
|
||||||
|
encrypted_priv_key
|
||||||
|
).await?;
|
||||||
|
|
||||||
// user might no have filled his details yet, but personal id number is filled from beginning
|
// user might no have filled his details yet, but personal id number is filled from beginning
|
||||||
let personal_id_number = EncryptedString::from(candidate.personal_identification_number.clone())
|
let personal_id_number = EncryptedString::from(candidate.personal_identification_number.clone())
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue