mirror of
https://gitlab.com/comunic/comunicapiv3
synced 2024-11-25 23:09:22 +00:00
Inverted first and last name when creating account
This commit is contained in:
parent
4a2784919b
commit
d3c1ee700d
@ -28,8 +28,8 @@ use crate::utils::user_data_utils::user_data_path;
|
|||||||
/// Create a new account
|
/// Create a new account
|
||||||
pub fn create(new_account: &NewAccount) -> ResultBoxError {
|
pub fn create(new_account: &NewAccount) -> ResultBoxError {
|
||||||
database::InsertQuery::new(USERS_TABLE)
|
database::InsertQuery::new(USERS_TABLE)
|
||||||
.add_str("nom", &new_account.first_name)
|
.add_str("prenom", &new_account.first_name)
|
||||||
.add_str("prenom", &new_account.last_name)
|
.add_str("nom", &new_account.last_name)
|
||||||
.add_str("date_creation", &mysql_date())
|
.add_str("date_creation", &mysql_date())
|
||||||
.add_str("mail", &new_account.email)
|
.add_str("mail", &new_account.email)
|
||||||
.add_str("password", &hash_password(&new_account.password)?)
|
.add_str("password", &hash_password(&new_account.password)?)
|
||||||
|
Loading…
Reference in New Issue
Block a user